70 likes | 189 Views
C language2. C data types. Qualifier . long - long int (4 bytes) short – short ing (2 bytes) signed – signed int = int unsigned –unsigned int =int (0-65535). Basic input/output function. Output printf (“format”,arg1,arg2,…) putch (char) puts (string) Input
E N D
Qualifier • long - long int (4 bytes) • short – short ing (2 bytes) • signed – signed int = int • unsigned –unsigned int =int (0-65535)
Basic input/output function • Output • printf (“format”,arg1,arg2,…) • putch (char) • puts (string) • Input • scanf (“format”,&arg1,&arg2,..) • ch = getch () • gets (string);
Printf (“The result is %f calculated by %f and %f \n, answer, width, height); • putch (a); // a – declared as a character • puts (s); // s – declare as a pointer of character
Scanf (“Enter 3 input value %d%d%d”, &width, &length, &height); • ch = getch() ; // get one character • char *s; // declare s as a pointer of char • gets(s) ; // get string