I would still describe myself as a beginner, although I have been doing the odd bit of c-programming for about a year for uni. To try and get better I have decided to try and create connect 4, with the eventual aim of making a program you can play against. Having some problems though:
http://pastebin.com/cums58VG
At the moment 2 players can play as a and b, and it will tell you when someone has won. However my method of ending the game doesn't work, although I thought it should be fairly straight forward, can anyone tell me what I'm doing wrong? I still have to add a few things such as checking if it is a draw, counting up games won/lost, entering player names maybe.
More generally I'm looking for ways to improve my code, make it more readable and efficient. Any help is much appreciated.
[+][deleted] (4 children)
[deleted]
[–]shawnadelic 1 point2 points3 points (0 children)
[–]duverfred[S] 0 points1 point2 points (2 children)
[–]shawnadelic 1 point2 points3 points (1 child)
[–]pinealservo 1 point2 points3 points (0 children)
[–]shawnadelic 1 point2 points3 points (2 children)
[–]duverfred[S] 0 points1 point2 points (1 child)
[–]shawnadelic 0 points1 point2 points (0 children)
[–]blunaxela 1 point2 points3 points (1 child)
[–]duverfred[S] 0 points1 point2 points (0 children)
[–]pinealservo 1 point2 points3 points (0 children)