Plu wrote:Robin wrote:Eamonn wrote:I didn't make this thread for people to tell each other whether their style was wrong or not, I made it so I could see how the majority type their code.
Lesson learned? If you ask programmers about their opinion on anything, you'll get a holy war. So why bother?
'cause if you're smart, you can use their holy war style posts to learn something worthwhile.
Working together and communicating are pretty crucial for anyone who wants to program in a team, so it's good to learn how others people do their stuff. And to make a few rules about it when you start up a combined project. I've really learned to appreciate using a specific style of formatting, because the one they have at my job might not be my favorite, and I do it completely different at home, but the fact that everyone in the team uses the same style makes code so much easier to read that it's totally worth it.
I
was working on a game in a team, but that died
![Sad :(](./images/smilies/ms-sad.png)
People left because others fought, and it went from like 6 to 2 in a week. So it ended up I got fed up. I don't care how other people lay out their code, as long as it's indented. Maybe it's just me coming from Python, but I like 4 whitespaces
![Razz :P](./images/smilies/ms-razz.png)
No idea why. Anything over 4 is too much IMO.
Really, the only thing you need to remember when programming is to
always indent. I spent about 2 hours indenting MBG correctly(I was using ZeroBrane that day, and it was indenting at 2 instead of 4), and so I saved it, opened it in Sublime Text and it was messed up again. I always try to keep my code indented right. It helps when debugging a
lot.