reset password
Author Message
kknaur
Posts: 540
Posted 11:15 Feb 09, 2014 |

I've said this in class a few times now, but no matter which compiler you use, you MUST include all of the necessary header / library files. 

Code::Blocks does not include any libraries by default and I used Code::Blocks to grade your assignments.  Visual studio on the other hand does include some header files automatically, but it does not add the include directive to your files.  When I go to grade your programs in Code::Blocks I get compile errors.

Good programming practice dictates that you include any header files that you need in your program, otherwise this is a compile error and makes your program less compatible.  Not everyone uses the same compiler so you should always include necessary header files.  From now on, missing header files that cause a compile error will count as an unacceptable program.

Also, if you are using Visual Studio, make sure you check the empty project option and don't include precompiled header files.

lmann2
Posts: 156
Posted 14:55 Feb 11, 2014 |

Along these lines...I generated this project using a 'new blank project' in codeblocks.  I noticed it auto generated a .depend and .layout file, but don't know if these need to be included in our lab submission.  Do we need to include these files in our lab submission?  

kknaur
Posts: 540
Posted 16:04 Feb 11, 2014 |

Nope, the .cpp and .h files are sufficient for me to grade the assignment.