Program involving pointers/class/vectors

Pages: 12
1
2
3
4
for(int Deg = 359;Deg < 360;Deg++)
     for(int Min = 55;Min < 60;Min++)
          for(int Sec = 55;Sec < 60;Sec++)
               for(int Tenths=0;Tenths<10;Tenths++)


this code would generally be in a function, with an appropriate name, so comments aren't really needed nor are long variable names. if you really wanted to be sure someone knows what it does, a single line comment above it would suffice.

I hate it when people type a comment every line for obvious things

1
2
3
4
int Deg =0;  //Degree Counter
int Min = 0; //Minute Counter
int Sec = 0; //Seconds Counter
int Tenths = 0;  //Tenths of seconds counter 


Last edited on
All right, we could probably gone forever. I guess everyone has their style that they like. For one's own projects they can do whatever suits them. For code to be looked at / used by / maintained by others, I imagine that everyone would somehow adapt to whatever suits / keeps happy the group as a whole.

Any way thanks for your input - even though it wasn't my thread. :D
I wrote a program that works fine but to be honest I'm not quite sure why it works.

JUST BE HAPPY IT WORKS!!!
Topic archived. No new replies allowed.
Pages: 12