Tuesday, October 29, 2013

Cisco Placement Papers-1

Cisco Placement Papers-1

SECTION 1:
1: A man went to market with some money.With that money he can buy 25
pencils or 15  notebooks.He kept 15% of that money for bus fare and with rest of
the money he purchased 5 notebooks,and 'x' pens.How many pencils he can purchase?

2:A man climbing a wall.For every 4 steps go up he will slipdown 2
steps.If he takes 12 min to 6 steps.how much time it takes to climb 48
meters and one step=2meters.

3: Two trains with lengths x and y ,and speeds u and v.Approaching each
other how much time it takes to takes for faster train to cross other
train?
4  max distance between two points of a cube ans:2 Root 3
5. in a two digit no. sum of the two digits is equal to half of product of two.
 their product is equal to half of that reversed  two digit  number. then that no. is
ans:36
6.Annel is seven years younger than her brither whose age is half of his fother
 who is 10 yrs older than her mother.if mothers age is 40 what is annels age ans: 18
7. If a person gets 97 marks in a subject his avg. is 90%   If he gets 73 marks then
his avg. will be 80% what is the total of two subjects ?
8. 0<s*t<1
ans:c)s>-1 & t<-1
9. A cube of 3*3*3 dimenson is red painted and is devided in to 1*1*1* cubes (27pieces)
find the no. of pieces which have two faces red painted. ans: 12 (verify)


Section2:

1.
  main()
      { fork();
        fork();
        fork();
             printf("hello");
         }
       How many times it will print hello? ans:8
2:  char A[5,6]
   How many bytes it requires? ans:6

3:Bridges are used in which layer? ans:data link layer

4.Bigendian means
        a)lower byte stored in higher address
        b)lower byte stored in lower address    ans:a

5:
  #define mmx 10+10

   printf"%d",mmx*mmx);  ans:120

6:  i=1; j=1;
    main()
    {
       for(i=0;i<10;i++) (some one find semicolon at the end of for loop
                                then the ans: 10 11)    
             {
                 j+=i;
             }
     }
     what is the value of i & j at the end of the loop
  ans: 10,46

7: Regular expression with 2 consecutive 1's and all string of 0's and 1's

8:dead lock conditions 1 question


9: selective repeat the max seq.no is n. then the no.of outstandin packets?

10  For balancing the binary tree which one is good method ?
a)change the root entry at every insertion & deletion
b)rotation of subtrees. is the ans:
11. A positive NAND is eaqual to -ve logic----
    a)xor b) NOR c) NAND
12.How to access member x in   struct s1{struct{sruct{char x;}s2:}s3;}x;
ans: x.s3.s2.x
13.The size of the virtual memory addresable in 32 bit proc.(address bus) having
       2 power 16 size physical memory ?
a) 2 power 32 -1    b) 2 power 16. etc.
14.print the output of the following alg.
     1) set x=1
      2) set y=1
      3) x= xy
       4) y = y+2
    5)  if y>11 then goto then goto 6. else goto 3.
    6)  print x
  ans: x=10395
15) memory allocated in declaraton   extern double x
      ans: since it is not external defintion no memory is allocated.
16) struct s {.....} *s1;   s1=(sruct s* ) malloc (size of (struct s)+ 95* size of (int))
       free(s1);
    ans: all of the memory allcated will be released.
     b) 95* sizeof(int) will be leaked out
17) No. of  nodes in complete binary tree of height h is ..
18)On a 32 bit computer union{ double * p , int i, char c}a;
     a.p=malloc(8*size of (double)); printf("%d", size of (a));
        a)8 is the ans. b)5 c) 13 d) 4
19.   depth buffer algo. is used for
   ans:hidden surface elimination.
20)char c; while((c=getchar())!EOF); which one is true
a)c must be int
b)loop will exits if EOF occurs.
d)all ofthe above
21)static double * p=malloc(sizeof (double));  this not worked because
      a)fuction call is not allowed at the declaration
      b) no memory allocation for static ptr.
      c)it work s fine
22)  char b = 0xaa; b>>4; printf("%x",b);
   a) 000000AA
     b)00A0 etc.
23)If a pointer P   points to  some array then P++ will
a) point to next element  is the ans:
b)pont to next byte
24)enum{satday= -1,  sun,mon, tue, wed, thu, fri}days;
    printf("%d%d",wed, sizeof(days);
25)worstcase binary search tree complexity ?
ans   a)log(2 Power n)                = O(n)


No comments:

Post a Comment

ShareThis

Related Posts Plugin for WordPress, Blogger...