General Requirement Solve Hand Try Solve Without Using Compiler Q43887070
General requirement is to solve it in hand and try tosolve without using any compiler.
![Exercise on Strings 1.) What would be the output of the following programs: (a) main() maino (b) char c[2] = A: printf (n](https://media.cheggcdn.com/media/91c/91cb65e8-5ebd-4b28-b1b1-dea464d515df/image.png)
Exercise on Strings 1.) What would be the output of the following programs: (a) main() maino (b) char c[2] = “A”: printf (“n%c”, c[0]); printf(“n%s”. c): char[] = “Intro to programming with C!” ; printf(“n%s”, &s[2]): printf(“n%s”. s): printf(“n%c”. [2] Output: Output: main char s[] = “Weird syntax”; int i = 0; while( [0] = ‘ ‘) (d) int main(void) { char arr1[10] = “test1”; char arr2[20] – “Test1”; if(strcmp(arri, arr2)<o) printf(“arri smaller”); else if(strcmp(arri, arr2)–) printf(“Same”); else printf(“arri is larger”); printf(“n%c%c”, s[0]. ( + )); printf(” %c %c”, i[s], (i+s)) Output: return; (e) int main() { char s[. “Da gaad feel gaad.” ; char x = ‘0’; char t[25] ; strcpy(t, s); int i-e; while (s[i] != ‘ ‘ ) { if (t[i] == ‘a’) *(s+i)= x Output: (f) void encrypt(char A[][20], int cypher, int size) { for(int i 0; i<size; i++) for(int j-o; A[i][j] I. ‘le’; j++) A[i][j] – A[i][j] + cypher; int main(void) { char arr[4][20] – { “ford”, “nissan”, “accura”, “audi” }; encrypt(arr, 2, 5); for(int i = 0; i<4; i++) { printf(“%sn”, arr[i]); printf (“n%s”, s); return 0; return ; Show transcribed image text Exercise on Strings 1.) What would be the output of the following programs: (a) main() maino (b) char c[2] = “A”: printf (“n%c”, c[0]); printf(“n%s”. c): char[] = “Intro to programming with C!” ; printf(“n%s”, &s[2]): printf(“n%s”. s): printf(“n%c”. [2] Output: Output: main char s[] = “Weird syntax”; int i = 0; while( [0] = ‘ ‘) (d) int main(void) { char arr1[10] = “test1”; char arr2[20] – “Test1”; if(strcmp(arri, arr2)
Expert Answer
Answer to General requirement is to solve it in hand and try to solve without using any compiler. …
Related