AgreeYa Aptitude Technical Test December 2011

Posted on :06-04-2016

Q1. If A wins in a race against B by 10 mts in a 100 Meter race, if B is behind of A by 10 mts, then they start running race, who will won?

ANS: A

Q2. In a game I won 12 games, each game if I loose I will give you one chocolate, you have 8 chocolates how many games played?

ANS: 32

Q3. What is the probability to get tail, at least once when 6 coins are tossed simultaneously?

ANS:  63/64.

Q4. 75 persons major in physics, 83 major in chemistry, 10 not at major in these subjects. Find number of students majoring in both subjects.

ANS: 68.

Q5. Five friends can sit in 120 ways, how many arrangements are possible if Mohan has to sit in the middle?

Q6. What is the output of the following program?

# define swap (a,b) temp = a; a=b; b=temp;
main( )
{
int i, j, temp;
i=5;
j=10;
temp=0;
if( i > j)
swap( i, j );
printf( %d %d %d, i, j, temp);
}

ANS: 10, 0, 0

Q7. In the following program:

main( )
{
unsigned int i=3;
while( i >=0)
printf( %d, i--);
}

how many times will the printf statement be executed?

a) 0
b) 3
c) 4
d) infinite

Q8. Output of the following program is:

main()
{int i=0;
for(i=0;i<20;i++)
{switch(i)
case 0:i+=5;
case 1:i+=2;
case 5:i+=5;
default i+=4;
break;}
printf(%d,,i);
}
}

a) 0, 5, 9, 13, 17
b) 5, 9, 13, 17
c) 12, 17, 22
d) 16, 21
e) Syntax error

ANS: d

Q9. What is the output of the following program?

main( )
{
int x, y, z;
x=2;
y=5;
z= x+++y;
printf(%d %d %d, x, y z);
}

a) 3 5 7
b) 5 7 9
c) 6 8 5
d) 3 6 9

ANS: a

Q10. What is the output in the following program?

main()
{char c=-64;
int i=-32
unsigned int u =-16;
if(c>i)
{printf(pass1,);
if(c
printf(pass2);
else
printf(Fail2);
}
else
printf(Fail1);
if(i
printf(pass2);
else
printf(Fail2)
}

a) Pass1, Pass2
b) Pass1, Fail2
c) Fail1, Pass2
d) Fail1, Fail2
e) None of these

ANS: (c)

Latest Current Affairs

FreshersLive - No.1 Job site in India. Here you can find latest 2020 government as well as private job recruitment notifications for different posts vacancies in India. Get top company jobs for both fresher and experienced. Job Seekers can get useful interview tips, resume services & interview Question and answer. Practice online test free which is helpful for interview preparation. Register with us to get latest employment news/rojgar samachar notifications. Also get latest free govt and other sarkari naukri job alerts daily through E-mail.

 ✖