I have a problem with the raw_input function. I call it two times, to write the row and the column, but it seems to work just one time. It did work during previous steps and I didn’t change anything in the code, but now it just lets me put only one number.
guess_row = int(raw_input("Guess Row: ")) guess_col = int(raw_input("Guess Col: ")) if guess_row==ship_row and guess_col==ship_col: print("Congratulations! You sank my battleship!") elif board[guess_row][guess_col]=="X": print("You guessed that one already") else: if guess_row not in range(5) or guess_col not in range(5): print("Oops, that's not even in the ocean.") else: print("You missed my battleship!") board[guess_row][guess_col]="X" print_board(board)
This is the part where it stops working correctly. It looks like this on the console:
Anyone had similar problem?