Computer Sciences > Gate 2019 > Functions
Consider the following C program:

#include <stdio.h>
int jumble(int x, int y) {
    x = 2 * x + y;
    return x;
}
int main() {
    int x = 2, y = 5;
    y = jumble(y, x);
    x = jumble(y, x);
    printf("%d ", x);
    return 0;
}


The value printed by program is __________

Correct : a

Similar Questions

The following function computes the maximum value contained in an integer array p[] of size n (n >= 1) int max(int *p, int n) { &nbsp; &nbsp; int a=0, b=n...
#123 MCQ
Consider the following C program. void f(int, short); void main() { &nbsp; &nbsp; int i = 100; &nbsp; &nbsp; short s = 12; &nbsp; &nbsp; short *p = &s; &...
#144 MCQ
Consider the following function implemented in C: void printxy(int x, int y) { &nbsp; &nbsp; int *ptr; &nbsp; &nbsp; x = 0; &nbsp; &nbsp; ptr = &x;...
#159 MCQ

Related Topics

No tags found

Unique Visitor Count

Total Unique Visitors

Loading......