Pointers - Find Output of Program Multiple Questions and Answers.




16.What will be the output of the program?
A. peace
B. eace
C. ace
D. ce

17.What will be the output of the program?
A. llo
B. hello
C. ello
D. h

18.hat will be the output of the program assuming that the array begins at location 1002?
#include<stdio.h>
int main()
{
    int a[2][3][4] = { {1, 2, 3, 4, 5, 6, 7, 8, 9, 1, 1, 2}, 
                       {2, 1, 4, 7, 6, 7, 8, 9, 0, 0, 0, 0} };
    printf("%u, %u, %u, %d\n", a, *a, **a, ***a);
    return 0;
}
A. 1002, 2004, 4008, 2
B. 2004, 4008, 8016, 1
C. 1002, 1002, 1002, 1
D. Error

19.What will be the output of the program?
A. 5
B. 25
C. 125
D. Garbage value

20.What will be the output of the program?
A. Alice
B. ecilA
C. Alice lice ice ce e
D. lice ice ce e

«»



Date to Date Current Affairs 2022

PakMCQs.net

Quick Links

GAT Subject



   Computer Science    English Mcqs    Agriculture    

Engineering



   Computer Science    Civil Engineering    

Technical



   Networking    Electronics    Database    

Past Papers



   Model Papers    FPSC Papers