

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
#include <stdio.h> void main(void) { int i = 1; unsigned u = 2; long l = 3; float f = 4.0; double d = 5.0; char c = 6; unsigned char uc = 7;.
Typology: Summaries
1 / 2
This page cannot be seen from the preview
Don't miss anything!


void main(void) { }
#include <stdio.h> void main(void) { int i = 1; unsigned u = 2; long l = 3; float f = 4.0; double d = 5.0; char c = 6; unsigned char uc = 7; printf("i = %d, u = %u, l = %l, f = %f, d = %lf, c = %c, c = %d, uc = %d\n", i, u, l, f, d, c, c, uc); printf("print a tab by \t and new line by \n"); }
#include <stdio.h> void main(void) { int i; printf("Print a prompt for i\n"); scanf("%d", &i); }
if(flag) { // put some statements here to execute if flag is true (flag != 0) } if(flag) { // put some statements here to execute if flag is true (flag != 0) } else { // put some statements here to execute if flag is false (flag == 0) } switch(flag) { case 0: // statements break; case 1: // statements break; case 2: // statements break; default: // statements }