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)
Programming TipsJatin Gandhi 6.3
Pointer Tips :-)Jatin Gandhi 6.8
Fast multiplicationJean-François Geyelin 6.7
merqery in cjeevan 0.0
Initialise all variablesJia.Lu 6.2
The power of scanf()Joanna 8.6
Fast way to reverse the bits in a byteJohn Hite 1.0
XOR swap: Swaping the values of 2 variables.John Rambo 0.0
compiler tipJulian Sutherland 6.2
Prefer pre-increment and pre-decrementKarl 5.9
Automatic Array initialisationkedar 7.0
assert() yourself!Kevin Lam 7.4
Do NOT always check for NULL! (C++)Kevin Lam 6.1
decoding * and inc/dec operator combos like *++p , *p-- ,etckishore 0.0
loop conditionKrishna 6.4
Pointer Memory allocationKrishnamoorthi 6.8
Use templates to prevent memory leakageKunal 5.6
Increment and decrement counters with rolloverLee Walker 3.6
backups using CVS save you lot of spaceLeif 6.2
Doing calculationsLinuxguru 5.5
One instruction per lineLudovic Flender 6.0
Keep fit to program betterLuna Man 6.9
logical error on divisionM.Kumaran 7.6
match the out side world ideas to logical designinmady 5.3
Use the Appropriate VariablesMahesh Kumar.S 5.5
clean up after cin (C++)Major_Small 6.6
Be careful of Magic behaviour due to compilers manik 5.7
Give Proper Names to Your VariablesMaragato 5.4
Turn on all compiler warningsMaragato 5.8
In C++ a pure abstract base class is a contractMarty Corbett 8.3

Next 30
Previous 30

Help your fellow programmers! Add a tip!