C and C++ Programming Tips

Welcome to Cprogramming.com's repository or tips for programming in C and C++. Peruse the archives or add your own tips for others to use!

Sort by clicking on any of the headers.

TipAuthorRating (votes)
loop conditionKrishna 6.0
logical error on divisionM.Kumaran 6.0
Dont't use scanf() when reading sentencesRomnico 6.0
One instruction per lineLudovic Flender 6.0
creating a messagebox on WindowsAmarjeet Kawathe 6.0
Count number of bits in an integer.Anjani Kumar Mishra 6.0
Make backupsVox 6.0
Reuse Old CodeTimofei Gerasimov 6.0
Pointer arithmetic trickinessvishesh jain 6.0
Temporariless SwapGuille 6.0
Effective Modularity in ProgrammingSharma PCS 6.0
gets is dangerouscarl johnson 6.0
Executing system commandsSean 6.0
Common Optimization TipsTravis Fischer 6.0
Avoid void main()Webmaster 6.0
Copy constructorAli Nawkhas Murad 6.0
String to integerMayur Avhad 5.9
Use const variables as function parameters when pobeyonddc 5.9
Use virtual functions instead of type checkingSajan 5.9
Always write if statements with bracesWebmaster 5.9
Avoid stl set non-const iteratorsIgor 5.9
Passing a pointer to a functionIrfaan Kamo 5.9
Declaration of abstract class in c++Ali Nawkhas Murad 5.9
think before you codeTimofei Gerasimov 5.9
Prefer pre-increment and pre-decrementKarl 5.9
Standard Loop ProgressionDazzle 5.9
Keep a cool head when programmingSentralia 5.9
Display Date and Time in C++Govind 5.9
pre & post increment & decrement operators jay 5.9
Using _strtime and _strdate to get the timeAli Jafar 5.9

Next 30
Previous 30

Help your fellow programmers! Add a tip!