working on the function checkForWin and a test for it
Updated checkforwin