Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Webpage for Programming:
Recent questions tagged programming
2
votes
3
answers
211
GO Classes Scholarship 2023 | Test | Question: 27
What will be the number of recursive calls for $\textsf{mystery(5)}$ including the first call? void mystery(int n) { if (n == 0 || n == 1) return 0; mystery(n-2); printf("%d", n); mystery(n-1); }
What will be the number of recursive calls for $\textsf{mystery(5)}$ including the first call?void mystery(int n) { if (n == 0 || n == 1) return 0; mystery(n-2); printf("...
GO Classes
563
views
GO Classes
asked
Aug 6, 2022
Programming in C
goclasses-scholarship-test1
numerical-answers
goclasses
programming
programming-in-c
recursion
1-mark
+
–
3
votes
1
answer
212
GO Classes Scholarship 2023 | Test | Question: 28
What will be the output of the following program? #include<stdio.h> struct _go{ char b[20]; char *a; struct _go *c; }x[2] = {"GATE", "2023", x+1, "GO", "Classes", x}, *p = x; typedef struct_go go; go ... ;c, n-2); } int main() { printf("%s",mystry(p,2023)->a); } GATE $2023$ Run time error GO
What will be the output of the following program?#include<stdio.h struct _go{ char b[20]; char *a; struct _go *c; }x = {"GATE", "2023", x+1, "GO", "Classes", x}, *p = x;...
GO Classes
734
views
GO Classes
asked
Aug 6, 2022
Programming in C
goclasses-scholarship-test1
goclasses
programming
programming-in-c
structure
recursion
2-marks
+
–
1
votes
2
answers
213
GO Classes Scholarship 2023 | Test | Question: 29
In which of the following case(s) character array must end with null char? char c[] = "GATE"; char c[] = {'2', '0', '2', '3'}; char c[4] = "GATE"; char c[16] = "2023";
In which of the following case(s) character array must end with null char?char c[] = "GATE";char c[] = {'2', '0', '2', '3'};char c[4] = "GATE";char c[16] = "2023";
GO Classes
1.2k
views
GO Classes
asked
Aug 6, 2022
Programming in C
goclasses-scholarship-test1
goclasses
programming
programming-in-c
array
multiple-selects
1-mark
+
–
4
votes
3
answers
214
GO Classes Scholarship 2023 | Test | Question: 30
Consider the following C code fragement - #include<stdio.h> int main() { char t[] = "abcdefghij"; int *p = t; p+=2; char *c = (char *)p; printf("%c", *c); } Which of the following is/are correct? The ... $\textsf{ i "}$ (without quotes).
Consider the following C code fragement -#include<stdio.h int main() { char t[] = "abcdefghij"; int *p = t; p+=2; char *c = (char *)p; printf("%c", *c); }Which of the fol...
GO Classes
1.1k
views
GO Classes
asked
Aug 6, 2022
Programming in C
goclasses-scholarship-test1
goclasses
programming
programming-in-c
array
pointers
multiple-selects
1-mark
+
–
2
votes
2
answers
215
what is the ouput of this c code ?
// C/C++ program to demonstrate return value // of printf() #include <stdio.h> int main() { long int n = 123456789; printf("While printing "); printf(", the value returned by printf() is : %d", printf("%ld" ... : 9 123456789 but this prints While printing 123456789, the value returned by printf() is : 9 why this is happens ?
// C/C++ program to demonstrate return value// of printf()#include <stdio.h>int main(){ long int n = 123456789; printf("While printing "); printf(", the value re...
ykrishnay
667
views
ykrishnay
asked
May 23, 2022
Programming in C
programming-in-c
programming
input-output
+
–
6
votes
4
answers
216
GO Classes Weekly Quiz 2 | Programming in C | Propositional Logic | Question: 2
What will be output printed by the following program? #include<stdio.h> main() { int c=4; switch(c) { c=c-1; case 4: printf("IITB "); break; default: printf("IISc "); case 3: printf("IITM " ... ;); } } $\text{IITB IITM}$ $\text{IITB IISc IITM}$ $\text{IITB}$ $\text{IITB IITM IITD}$
What will be output printed by the following program?#include<stdio.h main() { int c=4; switch(c) { c=c-1; case 4: printf("IITB ")...
GO Classes
1.0k
views
GO Classes
asked
May 2, 2022
Programming in C
goclasses_wq2
goclasses
programming
programming-in-c
output
1-mark
+
–
7
votes
2
answers
217
GO Classes Weekly Quiz 2 | Programming in C | Propositional Logic | Question: 3
Trace the execution of the following if statements and select the output from this code fragment int main() { int a = 3, b = 7 ; if ( (a + b) % 2 != 0 ) { printf("tetrahedron\n" ... a ) { printf("octahedron\n"); } else { printf("dodecahedron\n"); } } Tetrahedron Cube Octahedron Dodecahedron
Trace the execution of the following if statements and select the output from this code fragmentint main() { int a = 3, b = 7 ; if ( (a + b) % 2 != 0 ) { printf("tetrahed...
GO Classes
742
views
GO Classes
asked
May 2, 2022
Programming in C
goclasses_wq2
goclasses
programming
programming-in-c
output
1-mark
+
–
6
votes
1
answer
218
GO Classes Weekly Quiz 2 | Programming in C | Propositional Logic | Question: 9
In $C$ programming, constant integers are considered to be signed integers by default. One way to represent them as an unsigned constant is by appending $U$ as a suffix. For example, $-1$ is signed whereas $-1U$ is unsigned. Which of the following ... $\text{TRUE}$? $-1 > -2$ $-1U > -2$ $-1 > 0U$ $-1 > 0$
In $C$ programming, constant integers are considered to be signed integers by default. One way to represent them as an unsigned constant is by appending $U$ as a suffix. ...
GO Classes
800
views
GO Classes
asked
May 2, 2022
Programming in C
goclasses_wq2
goclasses
programming
programming-in-c
number-representation
multiple-selects
2-marks
+
–
3
votes
1
answer
219
GO Classes Test Series 2024 | Programming | Test 3 | Question: 15
If the $32$-bit number given below is stored in little-endian at address $1000,$ what is the value of the byte at address $1002?$ Answer in decimal. $0001\; 0010 \;0011\; 0100\; 0101\; 0110\; 0111\; 1000$ This number is the same as $12345678$ in hexadecimal.
If the $32$-bit number given below is stored in little-endian at address $1000,$ what is the value of the byte at address $1002?$ Answer in decimal.$$0001\; 0010 \;0011\;...
GO Classes
432
views
GO Classes
asked
Apr 30, 2022
Programming in C
goclasses2024-programming-3-weekly-quiz
numerical-answers
goclasses
programming
programming-in-c
number-representation
2-marks
+
–
2
votes
1
answer
220
GO Classes Test Series 2024 | Programming | Test 3 | Question: 16
What will be printed by the following program? #include<stdio.h> int func(int n, int * fg) { int t, f; if (n <= 1) { *fg = 1; return 1; } t = func(n - 1, fg); f = t + *fg; *fg = t; return f; } int main() { int x = 15; printf("%d\n", func(5, &x)); }
What will be printed by the following program?#include<stdio.h int func(int n, int * fg) { int t, f; if (n <= 1) { *fg = 1; return 1; } t = func(n - 1, fg); f = t + *fg; ...
GO Classes
273
views
GO Classes
asked
Apr 30, 2022
Programming in C
goclasses2024-programming-3-weekly-quiz
numerical-answers
goclasses
programming
programming-in-c
functions
2-marks
+
–
Page:
« prev
1
...
3
4
5
6
7
8
9
10
11
12
13
...
32
next »
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register