GATE, NET
Description: GATE IT | |
Number of Questions: 20 | |
Created by: Shaka Gupte | |
Tags: IT System Study Computer Science & Information Technology - CS Design of Algorithm & Analysis Algorithms Programming - C / C++ |
Which model includes user participation in software development?
Which of the following is a header file for the inbuilt function iniscr ( ) in C language?
Consider the grammar: G1=({S,S1,S2},{a,b},S,P), with the following productions: P:S → S1bc,S1→ S1bc|S2,S2 →b Give the regular language for the above.
Which of the following is true about virtual base class?
Consider : 7*2n+n2 ≤ 6*2n for n ≥ 4 Find the complexity for the given equation.
What is the output of the given program snippet in C language?
main()
{
int x=10,a=20;
clrscr(); x=(a==!!a);
printf(%d,x&&a); getch();
}
How many minimum inputs would be required to get 37 output lines in a decoder?
What is the output of the given program snippet in C Language?
main()
{
int a=0.5,c=0.5;
float b=2,d=4;
if(b=d&&a++<=c) printf(This is true);
else
printf(This is false);
}
What will be the output of the following code snippet in C language?
main()
{
int j=0,i;
clrscr();
for(printf(nValue is not initialized here.);
j++;)
{
if(j>10) break;
else
{
i=j*2; printf(%d,i);
}
}
getch();
}
What will be the result of the given code snippet in C language?
main()
{
int x=1;
clrscr(); for(;x++;x%10?0:1)
{
printf(%d,x*x);
}
getch();
}
What will be the output of the following code snippet in C language?
Assume that all preprocessor directives are correct.
main()
{
int a=11;
clrscr(); a++ +=10;
printf("%d",a); getch();
}
Consider the following code.
What will be the values of a, x, y and z?
main()
{
int x=10,y=20,z=30,a=0;
clrscr();
a=(x+=y)||(y+=z);
getch();
}
What will be the output of the following code snippet?
main()
{
int a=11,b; clrscr();
for(a%10;a++);
printf(%d,a%10?0:1);
getch();
}
What will be the output of the following code snippet?
main()
{
int a=1,b=1;
clrscr();
a=++a||++b&&++a;
printf(a=%d, b=%d,a,b);
getch();
}
Consider the below given code:
main()
{
int i=0; //line 1
clrscr();
printf(%d,i); i++;
if(i!=10)
main();
getch();
}
The above code snippet will run in an infinite loop.
What resolution shall be applied in order to terminate the loop as well?
What will be the output of the following code snippet?
main()
{
int num=1;
clrscr();
for(j=1;j<=6;j++)
{
for(i=j;i>=1;i--)
{
for(k=1;k<=i;k++)
num*=k;
}
}
printf(The num is: %d,num);
getch();
}
Consider the given number system. (123)10 = (234)? What will be the base for 234?
Where is the file pointer fp pointing to after below mentioned statement? fseek(fp, 49, sizeof (Variable type),0);
What will be the output of the code snippet?
int funct(a,b)
int a,b;
{
return a*b;
}
void main()
{
int i=135,k;
clrscr();
k=funct(!++i,!i++);
printf(i=%d,k=%d,i,k);
getch();
}
What will be the output of the following code snippet?
main()
{
clrscr();
char ch[]=Hello;
switch(ch)
{
case world: printf(World);
break;
case Hello: printf(Hello);
break;
default: printf(default.);
}
getch();
}