This is my code for Battleship problem, the error is " it looks like you function did not print the correct response!"


board = [ ]

for x in range(5):

def print_board(board):
    for row in board:
        print " ".join(row)
print "Let's play Battleship!"


Hi, @alish0103,

For which Battleship! exercise did you submit this code?

Your code works correctly for Printing Pretty.

For the previous exercise, which is Custom Print, you need this ...

print row

instead of this ...

print " ".join(row)


It worked, thanks a lot. :slight_smile:


No problem; enjoy the exercises :smile: