As we have discussed, there are number of problems.
(Suggestion- the layman way: Just try to think, when a player can be decleared as a winner? Put that in a simple if else statement.You can use functional approach, to avoid complications while writing code)
#
#