I need to be able to count how many of the string \"O\" is in my list
top_board = [ [None, None, None, None, None, None, None, None, None], [None, None,
Since you asked for a function:
def count_O (top_board): if True in ["O" in e for e in top_board]: print "O found"