TCS  Placement Paper   General - Other   -1 Jan 2004

TCS  Placement Paper   General - Other   -1 Jan 2004

  • Posted by  FreshersWorld 
    7 Jan, 2012


    1.There are 45 questions, which include Unix, c & aptitude, in 35 mts.

    2.People say that cut of will be around 38-40 questions. All questions are objective type only. There won?t be any technical (about software) questions in software.

    Here are some of the questions,

    1. |x-a| = a-x solve.                                            Ans) x<=a

    2.There is a six-letter word UGANDA. How many ways u can arrange the letters in the word in such a way that both A's are together.            Ans) 120

    3.If two cards are taken one after another without replacing from a pack of cards. What will be the probability for 2 cards to be drawn?          Ans) 1/13 x1/17

    4.51x53x.....x59                                                           Ans) 99!x25!/2 power 24x 49!x5!

     5.The ratio of boys to girls is 6:4.60% of the boys and 40% of girls take lunch in the canteen.What % of class takes lunch?                        Ans) 52%

    6.& 7 à. 2 simple problems from data sufficiency (refer 1 or 2 test from ims)

    data sufficiency:

               a) only statement a is sufficient

               b) only statement b '

               c) both are necessary

               d) both are not sufficient

    7) Anna is the tallest girl

       a) anna is taller than all boys

       b) one ther similarly appers you have to study it cartefully and the choose the right answer

    8) Zulus always speak truth and hulus always speak lies.There are three persons A,B,and C. A met B and says "Iam zulu or iam hutus. We don't know what he exactly said then B meets C and says to C that A is a Zulu .Then C replies " No ,A is a hutu.

    a) How many zulus are there? (ans 2)

     who must be a Zulu ? and B (check)

    b) A father F has 5 sons p,q,r,s,t Not necessarily in this order. Two are of the same age The eldest and youngest cannot be twins. T is elder to r and younger to q and s has three older brothers

      1) who are twins

      2) who is the oldest and youngest

      3)who is the one having equal number of youngers and elders

    8) There are 7 people who take a test among which M is worst. R is disqualified , P and S abtain same marks , T scores less than S and Q scores less than P , N scores higher than every one. N P S T Q R M ( may be correct  it) and some questions will come on this

    UNIX & C

    unix commands:-fork,tar,chmod,yacc,find,compress,make

    C:- know about calloc,exit(),pointer and arrays,pointer to functions(5 th chapter in K & R c book.(pointer fn. arguments thro'pointer). some protype functions like swap, sinfunction in math.h

    1)  -pointer arithmetic

    -what is the value of "i"?

    i=Strlen("BLUE") + strlen ("purple")/strlen("red")-strlen("green")


    2) i=2


    answer check care fully may be 2223

    what is the output of the following statements(string)

    printf("what is /0 the output"):

    ans.what is

    3) some problem appears like this



      int i,a[10];

       int *x

       i = &a[6] - a;

     printf("%d", i);


    answers are given as 1 , 6 , not compiled , machine dependent ?answer is 6;


    4) main()


       int *x , y=2;

       int * fun(int* );

       x = (int *) malloc(sizeof(int));




     int* fun(int *a, int *b)


       *a = (*b)++;



     Program exactly i doesn,t know but the stress is on *a = (*b)++   but for me answers are not tallied i think the answer now is 2,3;  but in answers it is not given;

     5) struct pt

        { int x;

           int y;



      { pt ptr;

        int xtr}lt,*lptr=&lt;

    They will give some accessing methods of data but the correct one is    lptr->ptr.x;

    6) some problem is there which says some jumps but the correct one is  setjump and longjump ?you study the jumps and clarify it;

    7)  c prototype for math function                       Ans) external double sin(double);

    8) one problem on variables apperars  answer is "file" ?.  that is actually the scope of external static variable;

    9) Child process à fork (given in c programme)

    10) For parsing another problem?.. ans is lex and yacc;

    11) For backups and archives??.. ans is tar;

    12) one bit on redirection of std error.           Ans) may be $command > outfile 2>&1

    13)  int* p(char (*s)[]);

    14) what for chmod 654

        rw-rw-r--  check it

    15) main()

          {  char *s = "hello"

      char *m = " how are you";


      pritnf("%s",s) ;


     16) stdin, stdout, stderr files and how to redirect that files.

2009-2016 All rights reserved.