Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- char c = 'T' ,
- sz[99] = "SONY";
- //int nArr[99] = {100, 101};
- /////////////////////////////////////////////////
- int main() //
- {
- printf("%d\n", c);
- printf("%c\n", c);
- printf("%s\n", sz);
- printf("- - - - - -\n");
- for(int i = 0; i < 5; i++)
- {
- printf("%c = %d his address = %d \n", sz[i], sz[i], &sz[i]);
- }
- printf("- - - - - -\n");
- int nArr[99];
- for(int i = 0; i < 5; i++)
- {
- printf("%9d his address = %d \n", nArr[i], &nArr[i]);
- }
- }
- /*
- #include <stdio.h>
- int n = 1;
- /////////////////////////////////////////////////
- int main() //
- {
- switch(n)
- {
- case 1: printf("January \n"); // break;
- case 2: printf("February\n"); break;
- case 3: printf("March \n"); break;
- default: printf("Error ! \n");
- };
- }
- */
- /*
- #include <stdio.h>
- int n = 2;
- /////////////////////////////////////////////////
- int main() //
- {
- int i = 2;
- L_01:
- printf("%d * %2d = %2d\n", n, i, n*i);
- i += 1;
- if(i < 11) goto L_01;
- }
- */
- /*
- #include <stdio.h>
- int n = 2;
- /////////////////////////////////////////////////
- int main() //
- {
- int i = 2;
- do
- {
- printf("%d * %2d = %2d\n", n, i, n*i);
- i += 1;
- } while(i < 11);
- }
- */
- /*
- #include <stdio.h>
- int n = 5;
- /////////////////////////////////////////////////
- int main() //
- {
- int i = 2;
- while(i < 11)
- {
- printf("%d * %2d = %2d\n", n, i, n*i);
- i += 1;
- }
- }
- */
- /*
- #include <stdio.h>
- int n = 7;
- /////////////////////////////////////////////////
- int main() //
- {
- for(int i = 2; i < 11; i++)
- {
- printf("%d * %2d = %d\n", n, i, n*i);
- }
- }
- */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement