Cheatography
https://cheatography.com
Déclarations de variables
typename variablename; |
typename variablename = expression; |
Conditions
if (expressionBool) { ... } |
if (expressionBool) { ... } else { ... } |
if (expressionBool) { ... } else if (expressionBool) { ... } ... else { ... } |
|
|
Boucles
while (exprBool) { ... } |
do { ... } while (exprBool); |
for(init ; exprBool ; incr) { ... } |
For / While
for (a ; b ; c) { d; }
// equivalent to
a;
while(b) {
d;
c;
}
|
|
|
Afficher du texte
printf("hello");
|
hello |
printf("x = %d", 5);
|
x = 5 |
|
Created By
Metadata
Comments
No comments yet. Add yours below!
Add a Comment
Related Cheat Sheets