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)
The power of scanf()Joanna 8.0
Using _strtime and _strdate to get the timeAli Jafar 7.6
Better coding style for comparisonnids 7.3
swap with out using temporaryraghava 7.3
When optimizing code, focus on algorithms firstAlex Allain 7.2
logical error on divisionM.Kumaran 7.2
Comparisons in C\C++Nikitas Angelinas 7.2
Temporariless SwapGuille 7.1
Rounding to an IntegerGorn 7.1
difference between int* p and int *p declarationomprakash mishra 7.1
assert() yourself!Kevin Lam 7.1
Differences between class and structAli Nawkhas Murad 7.0
Never do unary minus on sizeofVaibhav 7.0
Always write if statements with bracesWebmaster 7.0
difference between float and doubleankit panwar 7.0
static member functions and this pointerdhruv shekhawat 7.0
Multiply rather than DivideReese Moore 7.0
Don't use strlen in a loop condition.anonytmouse 7.0
Display Date and Time in C++Govind 7.0
Be organisedProphet-Ex 7.0
Arguments for MainSajan 6.9
Solve Any Compiler Error EasilyWajahat Karim 6.9
Use virtual functions instead of type checkingSajan 6.9
gets is dangerouscarl johnson 6.9
Keep fit to program betterLuna Man 6.9
Common Optimization TipsTravis Fischer 6.9
Standard Loop ProgressionDazzle 6.8
Pointer Tips :-)Jatin Gandhi 6.8
Keep a cool head when programmingSentralia 6.8
Pointer Memory allocationKrishnamoorthi 6.8

Next 30

Help your fellow programmers! Add a tip!