Cadence Placement Paper (Aptitude & Technical)
Cadence Placement Paper (Aptitude & Technical)
Cadence Placement Paper (Aptitude & Technical)
1. Inorder and preorder trees (expressions) are given and postorder tree (expression) is to be
found out.
2. int v,u;
while(v != 0)
t = v % u;
v = u;
u = t;
x = 3, y = 2;
foo(x, y)
var integer x, y;
x = x + 2;
y = y + 3;
main()
x = 5;
y = 5;
foo(x, y);
print (x, y);
4. given a grammar, in which some productions of if then else etc were given. you had to choose
one option that can be derived out of the grammar.
6. ring counter's initial state is 01000. after how many clock cylces will it return to the initial
state.
7. some boolesn expression of the form x'y'z' + yz + .. ( something like this) find the simplified
expression
8. given 6 bit mantissa in 2s complement form and 4 bit exponent is in excess-4 form in a
floating point representation, find the number
9. A signed no is stored in 10-bit register, what is the max and min possible value of the number.
10. A room is 30 X 12 X 12. a spider is on the middle of the smaller wall, 1 feet from the top,
and a fly is ont he middle of the opposite wall 1 feet from the bottom. what is the min distance
required for the spider to crawl to the fly.
11. A man while going down in a escalator (which is moving down) takes 50 steps to reach down
and while going up takes 125 steps. If he goes 5 times faster upwards than downwards. What
will be the total no of steps if the escalator weren't moving.
12. 2/3 of corckery(plates) are broken, 1/2 have someother thing(handle) broken , 1/4 are both
broken and handle broken. Ultimately only 2 pieces of crockery were without any defect. How
many crockery were there in total.
13. __________________________________________________
___|___ ___|___ ___|___ |
|||||||
| |__ | |___ | |___ |
|_______| | |_______| |__not_ |_______| | |
||||
|____________________|_____________|____and_|___
boxes are negative edge triggered flip flops and 'not' and 'and' are gates. What is this figure.
ans- modulo-5
14. It is difficult to draw a figure but another question was in which some NAND and OR gates
were given.
ans - Z = true.
C & UNIX
7. i=2
printf("%old %old %old %old ",i, i++,i--,i++);
8. Using pointer, changing A to B and B to A is Swapping the function using two address and
one temporary variable. a,b are address, t is temporary variable. How function look like?
Ans : swap(int *, int *, int )
14. Clarifying the concept addresses used over array ; ie changing the address of a base element
produces what error?
16. Answer are lex 7 yacc & man read these things in UNIX
1. A sequence is given. You should find out error & write correct 1 2 5 10 13 26 29 48.
2. 2,3 6,7 14,15 29,46. Error is 46. In every pair you add 1 to get second number. Ans:29+1=30
Ans:25
4 .Rearrange MERGANY
5. Rearrange BBIRAT
Ans:RABBIT
6. there are 6 persons k,l,m,n,o,p to give seminar cond: 3 persons should give before lunch and 3
after lunch l should immediately precede the seminar of m there should be no gap between l and
m .....
ans: 1. L position is 2
2 m pos is 5
3. k pos is 4
ans:32
10. 1,2,2,4,8,?
ans:32
11. 55*55*55+45*45*45/55*55-55*45+45*45
ans:100
12. 4^^61 + 4^^62 + 4^^63 + 4^^64 . this sum is divisible by which of the following ?
ans:17
1. A sequence is given. You should find out error & write correct 1 2 5 10 13 26 29 48.
2. 2,3 6,7 14,15 29,46. Error is 46. In every pair you add 1 to get second number.
Ans : 29+1=30
Ans : 25
4 .Rearrange MERGANY
Ans : GERMANY (country)
5. Rearrange BBIRAT
Ans : RABBIT
6. (passage)
there are 6 persons k,l,m,n,o,p to give seminar
cond: 3 persons should give before lunch and 3 after lunch
l should immediately precede the seminar of m
there should be no gap between l and m .....
Ans : 1. L position is 2
2 m pos is 5
3. k pos is 4
7. (passage)
A is daughter of Y, Z is father of Y. Q is son of Z,
2. if m is brother of T, then
3. if Q is son of Z them
Ans : 32
10.1,2,2,4,8,?
Ans : 32
11. 55*55*55+45*45*45/55*55-55*45+45*45
Ans : 100
12. 4^^61 + 4^^62 + 4^^63 + 4^^64 . this sum is divisible by which of the following ?
Ans : 17