8/script.py has been moved


#1

<PLEASE USE THE FOLLOWING TEMPLATE TO HELP YOU CREATE A GREAT POST!>

<Below this line, add a link to the EXACT exercise that you are stuck at.>
https://www.codecademy.com/courses/learn-python/lessons/battleship/exercises/its-not-cheatingits-debugging?action=resume&link_content_target=interstitial_lesson

<In what way does your code behave incorrectly? Include ALL error messages.>

"Whoa there!

8/script.py has been moved. This will cause problems with this exercise, please move 8/script.py back to its original location, or reset your files. "

<What do you expect to happen instead?>
The code ran very well but then just before pressing “next” button, this error popped-up.

```python

from random import randint

board = []

for x in range(0,5):
board.append([“O”] * 5)

def print_board(board):
for row in board:
print " ".join(row)

def random_row(board):
return randint(0, len(board) - 1)

def random_col(board):
return randint(0, len(board[0]) - 1)

ship_row = random_row(board)
ship_col = random_col(board)

Add your code below!

guess_row = int(raw_input("Guess Row: "))
guess_col = int(raw_input("Guess Col: "))

<do not remove the three backticks above>

#2

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.