Question : IT / Programming BEST practice in the long run

Hi everyone,

  Learning programmer here :D. As of the moment I am doing programming work alone. Which is the best choice listed below, during programming:
 
  1. Simultaneously program and document (e.g. make procedure descriptions at once you've done this particular block of code)

  2. Program first then document when you're all done?

  Which from these methods, would you recommend?

  Which is faster and better long term?

  Any additional helpful and relevant information would greatly be appreciated :D TIA
 

Answer : IT / Programming BEST practice in the long run

>> So my question really is:  how can I tell the compiler that Class2 will be defined later.
If you preceed the two classes with forward references, as in:
class Class2;
class Class1;
then your code in http:#33219489 compiles. If you start getting into compilation issues as you add items to your classes, then just remember that you can have two header files, one for each class, and two .cpp files - again, one for each class; and that may help you out of any difficulties.
Random Solutions  
 
programming4us programming4us