Company Name : Samsung India Software Operations
Type : Experienced
Hi ,
I have appeared for samsung drive which was for experienced.
It consisted of a GSAT ( Global samsung aptitude test) followed by C written test.
GSAT was of 60 mins and there were two sections:-
- Quantitative ability :- It consisted of 25 data
interpretation questions of barchart , piechart . These were very simple , including some percentage related calculations. - General Reasoning :- It
consisted 25 questions like
Then there were six set question related to above situations like, out of these who can be driver , who all can sit together.
Second they gave immediate C written test , which consisted 25 questions.
1) 11^ 2 is equal to :
2) What does left shift operation do:
a) Substraction of number.
b) Addition of number.
c) Multiplication.
d) Division
b) Addition of number.
c) Multiplication.
d) Division
Ans : Division.
3) Consider following programmain(){
int z , x=5 , y=10 , a= 4 , b=2;
z= x++ + --y*b/a;
prinf("%d" , z);
}
3) Consider following programmain(){
int z , x=5 , y=10 , a=
z= x++ + --y*b/a;
prinf("%d" , z);
}
Predict output ??
4) main()
{
char * c[] = "I am following you , who are you?";
printf("%c %c" , *(c[0]+4) , *(*(c+0)+9));
}
{
char * c[] = "I am following
printf("%c %c" , *(c[0]+4) ,
}
5) void increment(int i){i++;
}
main(){
int i=0;
for(i=0;i<10; increment(i))
printf("%d",i);
}
}
main(){
int i=0;
for(i=0;i<10;
printf("%d",i);
}
Ans : infinite loop.
5) main(){
int *ptr[] = {1,2, 3,4,5,6,7,8,9};
int *a;
a= ptr;
ptr+=3;
printf("%d" , ptr-a) ;
}
5) main(){
int *ptr[] = {1,2,
int *a;
a= ptr;
ptr+=3;
printf("%d" , ptr-a)
}
6) void main(){
int b=0 , a= 10;
b=a++ + ++a;
printf("%d ,%d ,%d" , b,a++,++a);
}
int b=0 , a= 10;
b=a++ + ++a;
printf("%d ,%d ,%d"
}
Predict output??
9) What is difference between definition and declaration?
9) What is difference between
10) There were 4 questions realated to malloc and calloc.
11)If there are five variables A, B ,C ,D, E , these pushed into stack and then four were popped out and entered into queue. Then two were deleted and then remaining are again pushed into stack.
Then pop operation is performed once , which variable will pop out?? 10)
main(){
char *s[]= "hello";
char *ptr ;
ptr = malloc(sizeof(int)) ;
s=ptr;
}
What is wrong in above program
a) memory leak;
b) memory overwrite.
c) Error.
char *s[]= "hello";
char *ptr ;
ptr = malloc(sizeof(int))
s=ptr;
}
What is wrong in above program
a) memory leak;
b) memory overwrite.
c) Error.
For Further Reading,
0 comments:
Post a Comment