81. Which is the smallest number of 3 digits that is divisible by 2, 4, 8?
82. What will be the output for following code?
#include<stdio.h>
int func(int x, int y)
{
if (y == 0)
return 1;
else if (y%2 == 0)
return func(x, y/2)*func(x, y/2);
else
return x*func(x, y/2)*func(x, y/2);
}
int main()
{
int x = 2;
int y = 3;
printf("%d", func(x, y));
return 0;
}
#include<stdio.h>
int func(int x, int y)
{
if (y == 0)
return 1;
else if (y%2 == 0)
return func(x, y/2)*func(x, y/2);
else
return x*func(x, y/2)*func(x, y/2);
}
int main()
{
int x = 2;
int y = 3;
printf("%d", func(x, y));
return 0;
}
83. What is the output of the following code?
#include<stdio.h>
int get_sum(int n)
{
int sm, i;
for(i = 1; i <= n; i++)
sm += i;
return sm;
}
int main()
{
int n = 10;
int ans = get_sum(n);
printf("%d",ans);
return 0;
}
#include<stdio.h>
int get_sum(int n)
{
int sm, i;
for(i = 1; i <= n; i++)
sm += i;
return sm;
}
int main()
{
int n = 10;
int ans = get_sum(n);
printf("%d",ans);
return 0;
}
84. The shortest distance between a line and a point is achieved when?
85. Which of the following is not a transposition cipher?
86. What is the running time of Dinic's blocking flow algorithm?
87. Which type of graph has all the vertex of the first set connected to all the vertex of the second set?
88. The greedy algorithm can find a minimal vertex cover in polynomial time for which among the following?
89. Under what case of Master's theorem will the recurrence relation of binary search fall?
90. What is meant by integer partition?
Read More Section(Miscellaneous on Data Structures)
Each Section contains maximum 100 MCQs question on Miscellaneous on Data Structures. To get more questions visit other sections.
- Miscellaneous on Data Structures - Section 1
- Miscellaneous on Data Structures - Section 2
- Miscellaneous on Data Structures - Section 4
- Miscellaneous on Data Structures - Section 5
- Miscellaneous on Data Structures - Section 6
- Miscellaneous on Data Structures - Section 7
- Miscellaneous on Data Structures - Section 8
- Miscellaneous on Data Structures - Section 9
- Miscellaneous on Data Structures - Section 10
- Miscellaneous on Data Structures - Section 11
- Miscellaneous on Data Structures - Section 12