Anda di halaman 1dari 113

1.binary equivalent of 52 ---- 110100 2.Hexadecimal equivalent of 3452 ------ 72A 3.

A better way of unit testing s/w program is Ans.: User test 4.A lowest levels of security by most RDBMS are Ans.: a) field low 6.OOT use Ans.: Encapsulated of detects methods 7.EDI useful in Ans. : Electronic Transmission 8.MRPII different from MRP ANS: Modular version of man redundant initials 9.Hard disk time for R/W head to move to correct Ans.: a) Latency 10.Percentage of times a page number bound in associate register Ans. : Bit ratio 11.MODEM --------Modulation and Demodulation 12.RDBMS file system Ans.: Interrelated 13.Super Key is ----- Primary key Attribute 14.Transmission is said to be ----committed 15.Windows 95 supports a) Multi-user b) n tasks c) Both Ans.: c 16. Difference between printf and fprintf ---17.To change permission r&w to owner group to no permission to others a) Chmod 614 b) chmod 604 c) chmod 640 d) chmod 310 18.In batch process ------------better job SECTION-1 ********* 1. Five trays cost is 0.35 each and dozen----- (ans:Rs13.75) 2.In a journey of 15 miles two third distance was travelled remaining with 60 mph.How muvh time the journey takes... with 40 mph and (ans:20 min) to 12.00 on

3.A man walks from 9.15 to 5.15 from monday to friday and 9.00 saturday.Each day 0.45 min lunch. 5.How much time he walks in a week...(ans: 39hrs15min). 6.12 revolutions takes 1/8 th second time.In 20 seconds how many (ans:1920) 7.In 60 reems of paper 40 reems were utilised then what (ans:33.33%)

revolutions...

percent will remain...

8.A started at 9.00 am with 6 mph and B started at 9.30 am with 8mph in the same direction. At what time they will meet... (ans:11.00am) 9.In a storage stall of 5x3x2inch.How many blanks of size stored.. 2x1x1inch can be (ans:15) and 1/5 know (ans:35%) bikes of Rs500/(ans: 75)

10.In a company 3/5 of people know shorthand 1/4th know typing both. What fraction of people do not know both.. 11.A man how many bikes of Rs 14000 can buy by selling 2100 of each

13.A company requires 11,500 strength.present employees are 200 women , men and 6500 unmarried To reach the target how many women required to maintain the same ratio (ans : 300)

14.What is the time required to punch 1500 cards of 50 column each at the rate of 10,000 punches per hour (ans:7hr 30min) ANALYTICAL REASONING: ******************** a group of five persons A,B,C,D,and E and C are intelligent in English and Reasoning. and C are intelligent in English and General Awareness. and D are intelligent in Arithmatic and Inteview. is intelligent in Interview,reasoning and Arithe matic. and D are intelligent in Arithmatic and Inteview. is intelligent in Interview,reasoning and Arithe matic. and D are intelligent in Arithematic and General Awareness.

1) In a)A b)B c)E d)E c)E d)E e)B

1) Who is intelligent in English,arithematic,and general awareness (ANSWER:B) 2)Whois intelligent in english and reasoning but not in general awareness ans:A) 3)Who is intelligent in Arithematic,General Awareness and Interview (ans:D) (ans:C) (ans:E)

4)Who is intelligent in English General Awareness and Reasoning 5)Who is intelligent in Arithematic,Reasoning and Interview

2) Five persons A,B,C,D and E were travelling in a car.They weretwo ladies in


the group. Of them who knew the car driving onewas a lady.A is brother of D.B wifeof D,drve at the begining. E drive at the end. 1)Which of the following is a pair of brothers.(ans:A,D) 2)Who was the other lady in the group.(ans:C) 3)In the case of which the following pairs,no relationship can be established with one else in the group (ans:C,E) 4)How was E related to A.(ans:DATA INADEQUATE)

3) A man said to woman " your only brother's son is my wife's


brother". How is the woman related to the man's wife...(ans:AUNT) b)priviliged instruction e)none of the above c)floating poitnt exception ans: a ans: b

4.which of the following involves context switch,


a) system call d)all the above

5.In OSI, terminal emulation is done in a)semion b)appl.. c)presenta... d)transport

6....... 25MHz processor , what is the time taken by the instruction which needs 3 clock cycles, a)120 nano secs b)120 micro secs c)75 nano secs d)75 micro secs ans. : a (dannys choice) 7. For 1 MB memory no of address lines required, a)11 b)16 c)22 d) 24 ans: 16 8. Semafore is used for a) synchronization 9.

b) dead-lock avoidence c)box

d) none

ans : a

class c: public A, public B

a) 2 member in class A,B should not have same name b) 2 member in class A,C " '' '' " c) both d) none 10.OLE is used in a)inter connection in unix c)interconnection in WINDOWS NT main() { int x=10,y=15; x=x++; y=++y; printf("%d %d\n",x,y); } ` int x; main() { b)interconnection in WINDOWS

ans : a

int x=0; {

} Modify_value() { return (x+=10); } change_value() { return(x+=1); } 3.main() {

} x++; change_value(x); printf("Second Output : %d\n",x); Modify_value(); printf("Third Output : %d\n",x);

int x=10; x++; change_value(x); x++; Modify_value(); printf("First output: %d\n",x);

int x=20,y=35; x = y++ + x++; y = ++y + ++x; printf("%d %d\n",x,y);

4.main() { char *p1="Name"; char *p2; p2=(char *)malloc(20);

while(*p2++=*p1++); printf("%s\n",p2); } 5.main() { int x=5; printf("%d %d %d\n",x,x<<2,x>>2); } #define swap1(a,b) a=a+b;b=a-b;a=a-b; 6.main() { int x=5,y=10; swap1(x,y); printf("%d %d\n",x,y); swap2(x,y); printf("%d %d\n",x,y); } int swap2(int a,int b) { int temp; temp=a; b=a; a=temp; return; } 7.main() { char *ptr = "Ramco Systems"; (*ptr)++; printf("%s\n",ptr); ptr++; printf("%s\n",ptr); } --------------------------------------------------------------------8. #include<stdio.h> main() { char s1[]="Ramco"; char s2[]="Systems"; s1=s2; printf("%s",s1); } ----------------------------------------------------------------#include<stdio.h> 9.main() { char *p1; char *p2; p1=(char *) malloc(25); p2=(char *) malloc(25); strcpy(p1,"Ramco"); strcpy(p2,"Systems"); strcat(p1,p2); printf("%s",p1); } 1. what is the error in the following sequence of program. int i1; switch(i1)

} ----------------------------------------------------------------------main() { int x=10,y=15; x=x++; y=++y; printf("%d %d\n",x,y); } ---------------------------------------------------------------------SET - I A Word is formed by sequence of a & b. Whenever an interchange occurs thier adjacent letters are also interchanged. In the following questions the sequence is altered as eg): consider the sequence is AAABBB -if 34 is applied the result is ABBAAB -if 25 is applied the result is BBABAA 1. When 25 and 34 is applied to ABABBA ans : ABBABA 2. When 25 is applied twice to BABABA ans : BABABA 3. When 16 is applied twice to BABBAB ans : BABBAB 4. When 34 and 25 is applied to AAABBB ans : BABABA 5. To get BABABA from AAABBB ans : 25 and 34 SET II Consider the following function f(n,A,B,C) = AC , when n=1 = f(n-1,A,C,B) + f(1,A,B,C) + f(n-1,B,A,C) ,when 6. f(2,A,B,C) ans : AB 7. f(2,B,A,C) ans : BA 8. f(2,A,C,B) ans : AC 9. The total number of terms in f(4,A,B,C) is ans : 15 10. The total number of terms in f(5,A,B,C) is ans : 31 n>1 + AC + BC + BC + AC + AB + CB

printf("The value of I1 is :"); case 1: printf("%d",i1); break; case 2: printf("%d",i1); break; default : printf("Invalid entry");

SET III There are r flags and n distinct poles. Any number of flags can be in a pole. [ PERMUTATION AND COMBINATION ] 11. 12. 13. 14. r=4, n=5,find the number of ways in which the flags can placed n=4, r=5 n=5 , r=5,I pole has two flags r=4, n=5, I pole has 2 flags and III pole has 1 flag

SET IV The first part of compound word is given, guess the second part and match the meaning 15.The first part is "swan",meaning of second part is a. an aviation creture b. category c. not up d. a musical piece

16. The first part is "swans",meaning of second part is a. an aviation creature b. c. not up d.a musical piece 17. The first part is "fool",meaning of second part is ans : fool(proof) -->

18. The first part is "fools",meaning of second part is ans:fools (cap) --> HAT 19. The first part is "honor", meaning of second part is a. Valor b. your c. hard 20. The first part is "band".meaning of second part is ans:band(wagon)-->carrier 21. The first part is "lady",meaning of second part is ans:lady(bug) --> insect 22. The ,, ,, ,,"stair",meaning of second part is ans:stair(case)-->category

_________________________________________________________________________ 1.|x-a| = a-x solve. ans.x<=a

2.There is a six letterword 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.-what is the value of "i"? i=Strlen("BLUE") + strlen ("purple")/strlen("red")-strlen("green") i=2 printf("%ld%ld%ld%ld",i,i++,i--,i++):what is the output? 8.what is the output of the following statements(string) printf("what is 10 the output"): 9. what is the error in the following sequence of program. int i1; switch(i1) { printf("The value of I1 is :"); case 1: printf("%d",i1); break; case 2: printf("%d",i1); break; default : printf("Invalid entry"); } 10. what is an error in the following sequence of a program. int i1; switch(i1) { case 1: goto lure; ans:-1 ans 3232 ans.what is

break; case 2: printf("This is second choice"); break; default: printf("This is default choice"); } void fun(void) { lure: printf("This is unconditional jump"); } 11. What is an error in the following sequence of a program. int i; switch(i) { case 1: printf("This is first choice"); break; case j: printf("This is second choice"); break; case 1+2+4: printf("This is the third and last choice"); break; } 12. what is an error in the following sequence of a program. int i; switch(i) { default: printf("This is default value"); break; case 1: printf("This is first choice"); break; case 2: printf("This is the second choice"); } 13. Will the following be used as an identifier? a. sum_of_credits b. initial tree c. final_# d. while e. SECTION_6 f. bingo-square

g. 2_4_87

14. 15. 16. 17. 18. 19. 20.

Are the identifiers name and NAME are same? Is it right to type # of #define other than in first column? Does C require expressions to be enclosed in parenthesis for while loop? Will the preprocessor terminates with semicolon ? What is the return value of scanf statement? What will happen, if there are two statements (without grouping) in if condition and an else is there for that if. What will be the output of this program. int no_fish; no_fish=1; if (no_fish==1) printf("The water was to warm\n"); else ; printf("The wates were all fished out\n");

21.

Is parenthesis required for conditional expression in if condition? Data Sufficiency : a) only statement A is sufficent , B is not b) only statemnet B c) both are necessary d) both are not sufficient. 22. X is an integer. Is X dvisible by 5? A) 2X is divisible by 5. B) 10X is divisible by 5. Ans : A)

23. (A) Anna is the tallest girl (Q) . Is Anna the tallest in the class

(B) Anna is taller than all boys. Ans : c

24.Zulus always speak truth and Hutus always speak lies. There are three persons A,B&C. A met B and says " I am a Zulu or I am Hutu". We don't know what exactly he said. then B meets C and says to c that " A is a Zulu ". Then C replied " No, A is a Hutu ". How many Zulus are there ? Ans 2( check) Who must be a Zulu ? Ans B (check) 25.A father F has 5 sons, p,q,r,s,t. Not necessarly in this order. Two are of same age. The eldest and youngest cannot be twins. T is elder to r and younger to q and s has three older brothers q) who are the twins? s,t q) who is the oldest and youngest? q, (s&t) 26. There are 7 people who take a disqualified, P and S obtain same less than P, N scores higher than Ans : N P S T Q R M (may be, just C & UNIX -------27. What does chmod 654 stand for. 28. Which of following is used for back-up files? (a) compress (b) Tar (c) make (d) all the above 29. what does find command do ? 30. what does " calloc" do? Ans : A memory allocation and initialising to zero. 31 what does exit() do? Ans : come out of executing programme. test among which M is the worst, R is marks, T scores less than S and Q scores every one. check) or N S P T Q R M

Ans : _rw_r_xr__ Ans : b Ans : search a file

1. In a triangle ABC AB=AC then all the following are correct exept one. Find that. a) AB<AC+BC b)AC<AB+BC c)BC<AB+AC d) AB+BC>AC+BC 2. Ten years ago the father's age is seven times the son'sage. Two years later father's age is twice the son's. Then the find the ages. 3. The father's age is 3 times the son's. After 15 years its age becomes twice the son's. Find the son's age now. 4. Two times which are started from stations A and B which are seperated by 110 km. One train leaves station A at 7 am. and travels 20 kmph. The other train leaves station B at 8 am. will speed of 25 kmph. Then at what time will they meet if they are travelling in opposite direction. a) 7 am. b) 10 am. c) 12 noon. d) 11 am. 5) x+2y=2 , 2x-y=4 then i)x=2 ii)x=0 y=0 iii) x-y=2 a)i only b) ii only c) none

d)i and (

) only

6) In a family E is the father of two sons and a daugher who is unmarried. Daugher in-law is an officer whose brother_in_law A is Engineer. C is doctor. The sister of B is Violenist who learnt Violin from B's wife. Then 6) What is the relationship between A&B. (ans. brothers) 7) Who is the wife of B (ans. officer) 8) What is the relation between E&B. (ans. father and son) 9) In a word COINCIDENCE the 1st letter is interchanged with 3ed letter and 2nd letter with 4th and so on. So what is the seventh letter from the right after interchanging. ans is D. 10) Minmise 123658/234586= (ans is 0.52)

11) A and B can do a work in 6 days. B alone can do in 16 days.After 3 days B withdraws. Then how many days can be needed by A to do the work alone. 12) Two men and Three boys can do a work in 6 days. 3 men and 5 boys can do that work in 4 days. Then 8 men and 8 boys can do in how many days. 13)123 means LITTLE BRIGHT BOY and 435 means GIRL IS BRIGHT and 267 LITTLE THING LLOGAL . Then LITTLE is represented by_______. 14 ( R.S Agarwal suggested ) On same relation like HELMET-HEAD then HIDE _ ? ( BOUND ans.) 15. How many times a minute & hours hands will meet together in a day. ans. 22 times. 16. In a total of 36 vehicles after one car there is one scooter.After 2nd car there will be two scooters and after 3ed car there will be 3 scooters so on.then find the number of scooters in the right half of arrangement.ans. 13 check. 17. All Hoopes are Dupes i) All hoopes are fears All fears are liars ii) All dupes are liars so means ans is 2.

18). Find the statement which gives correct explanartion tothe contradictory statements. i). doctor told that "Drug adicts can not have their habit ii). some surveys indicate that all the drug addicts left their drug habit. a) . Doctor do not know about drug addicts. b). servays does not include every drug addict c). Drug addiction is a bad habit. d). will power make people leave their habbit. 19. A shop keeper selling a product for 10% discount to the market price.but by bourgaining he got 10% profit of the costprice.Market price is 300Rs. Find the cost price. 20. Customer needs 30% discount . But shopkeeper give 20% and 10% succesively. then a). Whether customer got less profit than what he needed. b).will he got more. c). no loss d). none 21. Cost price of two articles is 800. If he sells one article at 3/4 th of cost price and another article at 4/3 rd of cost price Then he will loss 12 Rs. Then SP of article is. a). 600,400 b). 500, 400 c). 500,500 d). none

22 What is the longest four digit numbr which when divided by 12,17,35 leavining same remainder 5 a) 8825 b)8725 c) 8025 d) none 23) If travels 300 meters in first two hours and next 200 mts in 3 hours and 150 meters in 2.5 hours. Find the avg speed. a) 56 b) 58 c)50 d) 60 ans)

60

Q 1-5: 1) 6 persons A,B,C,D,E,F are playing a game of cards . A's father and mother , uncle were in the gang. There were two women. B is the mother of A gets more points then her husband. D got more points then E but less then F. Niece of E got the lowest points. Father of A agot More points then F. But would not win the game. i). who won the game? a)A b) B c) F d) D ans: b ii) who got lowest points ? a) A b) C c) E d) B ans: a iii). who is the husband of B ? a) F b) E c) D d) c ans : c iV) B was one of the lady. who was other lady? a) C b) D c) E d) A ans: a v) who stood second in the game? a) A b) B c) C d) D ans: c NOTE: check answers. 6).A is the widow of B. B & C were the only children of E.C is unmarried and is a doctor. D is the grand daughter of E and studies science.How is A related to D a)Aunt b) daughter c) sister d) sister_in_law ans: b Follow the following for Q. 7-8. a) Only conclusion I follows definately. b) ,, II ,, c) Both I & II follow d) Neither I nor II follows. e) either I or II follows. 7). STATEMENTS: It is some times said that corruption is due to proverty and gross diparities. It is an uncalled for slurr on the poor. Because the poor in India are among the most unsight persons. conclusions: I. upsight persons can't be corrupt persons. II. Disparities of income make the people corrupt. ans: c 8) STATEMENTS: The Indian economy has suffered considerble stresses and strains during the lostthree years. The general picture is one of stagnations. conclusions: I. stresses and strains in economy lead to stagnation . II. Indian economy is stagnant. ans: e Q. 9-15 follow this answers. a) only inference I follows. c) Both I & II follow. b) only inference II follows. d) neither I nor II follows. ans: c ans: a ans: d

9). no hawk is a sparrow. All hawks are hens. Inferences: I. no hen is a sparrow. II. no sparrow is a hen. 10). all graduates are chairs. all chairs are tables. Inferences: I. all graduates are tables. II. all tables are graduates. 11) some birds are elephnts. some elephants are white. Inferences: I. some birds are white II. some white are birds 12) all fans are vans. none van is pan.

I. No pan is fan. 13). all boats are coats. I. all boats are shirts 14). no pen is hen. I. no pen is healthy.

II.no fan is pan. no coat is shirt. II. all shitrs are boats.

ans: d ans: a ans: d

some hens are healthy. II. no healthy thing is pen.

(1) (2) t (3) (4) (5)

APTITUDE PART A man bought two horses for Rs.924 each and sold one horse for 15% profit and the other for 15% loss.What is the net gain? Two pumps fill atank in 20 hrs. One pump fills the same tank 10hrs. faster than the other pump. In what time the other pump fills the tank? X men in Xhrs/day finish a work in x days. Y men in y hours per finish the work in (a) X**2/Y**2 (b)X**3/Y**2 (c) Y**2/X**2 (d) Y**3/X**2 8 men + 2 boys finish a work in 16 days. 2 men + 5 boys finish a work in 20 days. 8 men and 8 boys finish the same work in how many days? A & B are two trains, travell from X & Y stations to Y & X stations after crossing each other A takes 4 hrs.48 mins. to reach Y station. B takes 3hrs.20 mins. to reach X station. The speed A is 45kmph. Speed of B is ?
PROGRAMMING Section 1. executable file the following command can be used (a) cat (b) od (c) vi (d) ed ans : b 2. Assume the current directory contains 10 files and does'nt contain 'temp'. What will be the output of the follwing commands? $ls > temp $wc -l temp (a) 9 (b) 10 (c) 11 (d) undefined. ans : b 3. If one wants the output of one command( command1) to be printed inthe printer as well as to be added to another file (outfile) which one of the following is a currect command he can give? (a) $command1 >>outfile|tee lpr b) $tee -a command1 | lpr ans : d (c) $ command1 | tee outfile | lpr (d) $ command | tee -a outfile |lpr (4) In the shell program set -x will cause A. Execution of the commands in the background B. Execution of the commands in verbose mode C. Exit from the shell program. D. Exit from the shell program after executing the next command (5) ACL in UNIX refers to A. Acces Control List B. Action Control List C. Application Command Language D. Advanced C lanuage (6) The command echo* A. will print * on the screen B. will print contents of all the files in the current directory C. will list the files in the current directory D. will print the contents of all shell variables (7) ls || date will A. print the name of the files in the current directory B. print today's date and time C.(A) followed by(B) D. none of the above (8) The built-in shell variable $$ refers to A. printing numbers in dollar format B. proces id_ of last command C.proces id_of last background command issued D.proces-id of current shell (9) dd is mainly used for A. dealing with raw, unformated data, whatever the source B. dealing with data dictionary C. deleting a directory D. none of the above (10) vis in UNIX is A. a command that takes only one input

B. a command for deleting strange or unwanted charectors that may have crept into files. C. points non-printable characters in understandable format D. all of the above (11) Which of the following is true regarding the UNIX (i) Multiuser Operating System (ii)Multitasking Operating System (iii) Real timing Operating System A. i only B. i and ii only C. i and ii and iii only D. i and ii (12) ln command is used to A. link object codes into a executable code B. give two names to the same file C. set line numbers for the file D. none of the above (13) nohup command is used for A. protecting the execution of programmes from aborting when hangup signal is received B. changing the execution priority of the programes C. not hanging up of the modem D. disconnecting a node from the system (14) SCCS is a A. Tool for maintaining large programmes in a production environment B. Communication Protocol C. Shell Programming Language D. String processing utility (15) Which one of the following is true as long as UNIX is concerned A. One can do programming in C only B. It can support terminals capable of printing only uppercase characters C. The text files are sorted as it is in MS-DOS D. None of the above (16) Inside vi editor to replace the string /10/$/94 with 10/$$/92 globally the following command can be used A. :1,$ s/\/10\/\$\/94/10\/\$\$\/92/g B. :1,$ s/\/10\/\$\/94/10\/\$\/$92/ C. :s/10/$/94/10/$$/92/g D. :1,$ s/\/10\/$\/94/10\/$$\/92/g (17) The ed command without any argument A. will print the current working directory B. will make the home directory as current directory C. will ask for the directory to be used as the current directory D. will go to the previous directory (18) nice command is used A. to increase/decrease execution priority of a command B. to compress a file C. to run a programme at latter time D. to set the key board responce slower (19) What will be the output of the following command sequence $ x='I am x' $sh $echo $x A. I am x B. Blank line C. x D. None of the above (20) The command tr a-z 0-9 < x A. converts all the digits to lowercase alphabets B. converts all the lowercase alphabets to digits C. will give syntax error D. none of the above

SECTION 2: ---------1)study the following program #define MAX(x,y) ((x)>(y)?(x):(y) main() { intx=5,y=5; printf("maximum is %d",MAX(++x,++y));

} the outpput of the programis a)maximum is 7 (b)maximum is 5 (c)maximum is 6 d)none of the above 2)given the following definitions int *p,*q,r; int values[30]; p=&values[0]; q=values+29; r=++q-p; what will be the value of r ? a)address of q minus p b)number of elements in the array c)(value pointed by q)+1-(value pointed by p) d)none of the above 3)what will the output of the program? #include<stdio.h> //print the sum of the series 1/5+1/4+.... static int =5; main() { int sum=0; do { sum+=(1/i); }while(0<i--); printf("sum of the series is %d",sum); } a)it will print the sum of the series 1/5+1/4+....+1/1 b)it will produce a compolation error c)it will produce a runtime error d)none of the above 4)study the following program #include<stdio.h> main() { intoldvar=80;newvar=-80; int swap(int,int); swap(oldvar,newvar); printf("numbers are %d\t%d",newvar ,oldvar); } int swap(intolval,int neval) { int temval=olval; olval=neval; neval=temval; } the output of the program is a)numbers are 80-80 b)numbers are 80 80 c)numbers are -80 80 d)numbers are -80 -80 5 STUDY THE PROGRAM BELOW, WHICH OF THE FOLLOWING STATEMENT WILL MAKE PROGRAM WORK :main ()

{ int *! = 10 , *j=20; i=i*j; } A) B) C) D) Replace i = i*j; as i = (int) ((int) i * (int)j); No error Replacei= i*j;as i = (int*) ((int)i*(int)j); Replace i+i*j ; as i = (int) i* (int)j;

6 Study the following program #include<stdio.h> enum mode = {green,red,orange,blue ,white}; main () { green = green +!; printf("%d,%d",green,red ); } The output of the program will be :A) 1,1 B)0,1 C)No output, error in compilation

d)

None of the above

7 Study th following statements. #define DELAYTIME 1000 volatile extern int k; intj; for (i=0;i<DELAYTIME;i++); j=k; A)Volatile is meaningless for the variable k B)Volatile is meaningful for the variable k since k is external and can change C)Volatile is meaningless for the variable k since k is loop invariant D)None of the above. 8 Study the following program : #include<stdio.h> main() { char buff[] = "this is a test"; int i, *ptr; ptr = (int*)buff; for (i=0;*ptr; i++); printf("%c",*ptr++); } The following will be the output A)This is a test B) t'll print junk

C)Compilation error

D)None of the above

9 Select the explanation for the following declaration itn(*(*ptr)(int)) (void) A) ptr is apointer pointing to a integer function that takes an intvalues returns an integer which will points to a function with no argument. B) ptr is pointer to function that takes an int value returns a pointer to a function with ano argument which returns a integer c) This is not a valid C statement. D) None of the above. 10 Study the following program # include <stdio.h> char *c[] ={ "FILE", "EDIT",

"SEARCH", "COMPILE", }; HAR **cp[] = {c+3,c+2,c+1,c}; char ***cpp = cp; main() { printf("%s", **cpp); printf("%s"< *--*++cpp+3); printf("%s", *cpp[-2]+3); printf("%s\n",cpp[-1][-1]+1); }The output of this program is A) SEARCHFILEEDITCOMPILE B) SEARCHCOMPILEEDIT C) SEARCHEPILEDIT D) None of the above 11 What is the size of ptr1 and ptr2. struct x { int j; char k[100]; unsigned i; }; int *ptr1: struct X *ptr2; A) Same depending on the model used B) 2,104 C) 2, Undefined for memory is not allocated D)

2,4

12

If i = i * 16; Which of the following is a better approach to do the operation A) Multiply i by 16 and keep it B) Shift left by 4 bits C) Add i 16 times D) None of the above

13 What is the output of the following program #include<stdio.h> main() {int i = 0; switc(i) { case 0 : i++; case 1 : i++2; case2 : ++i; } printf("%d",i++); } output of the program :A) 1 B) 3 C) 4 D) 5 14 In the following , where means lseek(fd,0L,SEEK_END); where = tell(fd); A) End of file. D) In between head and end of file.

B)

Head of file

C) Cannot be defined

15 Assuming that you are using IBM PC ,you have to a file of 128 intergers into a character array of 256 characters . Which statement you use ? char buf[256]; int word[128]' int i; i varies from 0 to 255 in steps of 2 a) word[i]=buf[i+1]*0x100 + buf[i]; b) word[i]=buf[i]*0x100 +buf[i+1]; c) word[i/2]=buf[i]*0x100+buf[i+1]; d) word[i/2]=buf[i+1]*0x100 +buf[i]; 16 If i=5, what is the output for printf( " %d %d %d", ++i,i,i++); a) 5,6,7 b) 6,6,7 c) 7,6,5 d) 6,5,6

17 For the following code how many times the printf function is executed int i,j ; for(i=0;i<=10;i++); for(j=0;j<=10;j++); printf("i=%d,j=%d\n",i,j); a)121 b) 11 c) 10 d) None of the above 18 What is the output generated for the following code #define square (a) (a*a) printf("%d",square(4+5)); a) 81 b) 4 C) 29 D) None of the above 19 int p = p = The a) For the following statement find the values generated for p and q? p = 0, q =1; q++; p = ++q; q--; p = --q; value of p and q are:1,1 b) 0,0 c) 3,2 D) 1,2

20 What is the output generated by the following program ? #include<stdio.h> main() { int a , count; int func(int); for (count = 1 ;count <=5;++count) { a = func(count); printf("%d", a); } } int func(int x) { int y; y=x*x; return(y); A) 1234567 b) 2516941 C) 9162514 D) 1491625 ***** 1. In one shocking instance of ________________ research, one of the nations influential researchers in the field of genetics reported on experiments that were never carried out and published deliberately _________ scinetific papers on existed work. ans: Fradulent- deceptive 2. We need more men of culture eligitent we have too many ____ among us ans: philistines 3. Hide-bound choose nearest antonym ans: Open minded 4. She has been in her Bonnet She cantell ______ ans:Anto 5. If x-2y=2;2x+y=4 which of the following is right ans:d 6. If 2men and 7boys can do a work in 16days.3men and 8boys cand do in 12 days 8menand 8boys ? ans;6 7. Aperson wants 30% discount. But shopper gave 20% and 12%succesively discount then the person gets ans:29.6 8. The distance between A and B stations is 110 km. apart on a st.line. One train starts at A at 7am. and travels towards B at 20kmph. Another starts at B at 8am.and travels towards A at a speed of 25kmph. AT what time they will meet? ans:10am. 9. 2,2,6,52.5,157.5,630 find the wrong number ans:replace 52.5 by 45 10. 02,12,28,722,152,312,632 find thef wrong number ans. replace 28 by 32

11. Air resistance is proportional to square of the velocity at a speed of 3kmph. the resistance is 0.000045 gm/cm. An aeroplance is travelling at a speed of 250 kmph. What is the air resistance offered in kg/mit ans:0.03125 12. A person gives 10% discount and he revenues 10% in bargaining. The printed price is 330. What is actual price? ans:270 13. For what period of time for 1800 at 5% interest will give interest of 390% ans:13/3 14. 10 years back thef father age is 7 times of his son. After 2 years twice the age of the father is equal to 5 times of the son. What are their ages? ans;f->38,S->14 15. Train travels 100km. in first 2hrs. and 200 km. in 3hrs. and 150 km. in 2.5hrs. What is the avg. speex? ans;60kmph 16. A number when divided by 342 gives remainder 47 When the same number is divided by 19,what would be the remainder ? ans:9 17. A and B can do work in 6 days. B alone can do in 16 days. After 3 days of combined work B left. In how many days further A completes remaining work? ans:24/5 days 18. In a parking place there are 36 vehicles. After first one scooter is there. AFter 2nd car two scooters, after 34d car and so on.... How many scooters are there in second half of the row? 19. How many times do the hands of clock concide in a day? ans;22 20. Fraction and simplification one problem is there. The exact answer is 7/13.(this damn correct) 21. The least/greatest 4 digit numbers which when divided by 15,27,35, 42 leaves in each case a remainder 7 is ans: 1897,9457 ******* 1. If i = 5 what is the output of printf("%d %d %d", ++i ,i ,i++); a) 5,6,7 b) 6,6,7 c) 7,6,5 (ans) d) 6,5,5 2. For the following code how many times the printf func. is executed, Code is : int i,j; for (i = 0; i =8 && y >2; (false) f) a + b; (false) g) a = b;(true) h) c+4 ; (true) 3. answer the following in true or false (2 marks) a) int ctr ; is a valid variable declaration(true) b) scanf is a keyword(true) c) stdout is a standard I/P ( false) d) register variables can be used as loop index for faster access(false) e)a = (a>b) is valid statement( true) f) x = a>b ? x:y is a valid statement( true) g) given x=1,y=4,z=2 , a=9 and b=3, evaluate x = x*y/z +a/b ; the value of x = 5 (ans: true) h) volatile is a keyword (false) Give one line answers for the following questions: 4.int count = 11; (4 marks) while (--count+1) printf("count down is %d \n",count);

how many times the printf statement is executed? ans : 11. 5 How does an existing data type in c ? ans: typedef using define 6 What is the output generated for the following code. [1 m] #define square(a) (a*a) printf("%d",square(4+5)); 7 In the following enumeration declaration determine the value of each member. eenum compass {north =2 south ,east=1,west ans: North = 2, south=3, east =1, west =2. 8 for the following declaration union x{ char ch; int i; float j }u-var; what is the value of sizeof(u-var) ( ans:4.) 9. How many bytes of memory will the follwing arrays need ? (a) char s[80] ans: 80. (b) char s[80][10] ans: 800. (c) int d[10] ans: 20. (d) float d[10][5] ans: 200. 10 For the follwing statement find the values generated for p and q ? int p=0,q=1; p=q++; p=++q; p=q--; p=--q; The value of p equal to 1 and the value of q equal to 1. 11 Write an appropriate declaration for the follwing situations. (a) x: function returning pointer to array[] of pointer to function returning char. (b) Declare a function func that accepts two integer arguments and returning a pointer to a long integer. ans: long int *func(int int) 12 int size ,*int_ptr,table[20]; char ch,*char_ptr; double d,grid; Find out the value for the following statements. a)size=sizeof(int) = 2 b)size=sizeof(ch) = 1. c)size=sizeof(size)= 2. d)size=sizeof(table) =40. e)size=sizeof(grid) = 160. f)size=sizeof(char_ptr)= 4. 13 Give the name of the standard library function for the following a)string length ans: strlen. b)string compare ans: strcmp. c)string copy ans: strcpy. d)string concatenation ans: strcat. 14 Suppose i and j are both integer type variables, and j has been assigned a value of 5.Then find the valie of i for the following expressions. a)i=2*j-2*j/5. ans:8. b)i=j/2 ans:2. c)i=2*j/2 ans:4. d)i=(2*j)/2 ans:5.

15 What is the o/p generated by the following program ? main() { int n=10; int func(int); printf("%d",func(n)); } int func(int n) { if(n>0) return(n+func(n-2)); APTITUDE TEST 1) ONE RECTANGULAR PLATE WITH LENGTH 8INCHES,BREADTH 11 INCHES AND 2 INCHES THICKNESS IS THERE.WHAT IS THE LENGTH OF THE CIRCULAR ROD WITH DIAMETER 8 INCHES AND EQUAL TO VOLUME OF RECTANGULAR PLATE? ANS: 3.5INCHES 2) WHAT IS THE NUMBER OF ZEROS AT THE END OF THE PRODUCT OF THE NUMBERS FROM 1 TO 100 3) in some game 139 members have participated every time one fellow will get bye what is the number of matches to choose the champion to be held? ans: 138 4) one fast typist type some matter in 2hr and another slow typist type the same matter in 3hr. if both do combinely in how much time they will finish. 5) in 8*8 chess board what is the total number of squares refer odel ans:204 6) falling height is proportional to square of the time.one object falls 64cm in 2sec than in 6sec from how much height the object will fall. 7) gavaskar average in first 50 innings was 50 . after the 51st innings his average was 51 how many runs he made in the 51st innings 8)2 oranges,3 bananas and 4 apples cost Rs.15 . 3 ornages 2 bananas 1 apple costs Rs 10. what is the cost of 3 oranges, 3 bananas and 3 apples ANs Rs 15. 9)in 80 coins one coin is counterfiet what is minimum number of weighings to find out counterfiet coin 10)in a company 30% are supervisors and 40% employees are male if 60% of supervisors are male. what is the probability that a randomly choosen employee is a male or female? 11)statement: all green are blue are blue, all blue are white conclusion: I) some blue are green II) some white are green III)some green are not white IV) all white are blue a) he has given four choices like gre type 12)all teachers are students. some students are girls. this type of questions are there. we cant able to reproduce them. SECTION B (all multiple choices)
1.while((*p++=*q++)!=0){} is equal to a) b) c) d) 2.the function strcmp(str1,str2) returns 3. int *x[](); means 4.#define PRINT(int) printf("int=%d",int); main() {int x,y,z; x=03;y=-1;z=01; PRINT(x^x); z<<=3;PRINT(x); y>>=3;PRINT(y); } 5. struct list{ int x; struct list *next; }*head; the struct head.x =100 above is correct / wrong

6. '-'=45 '/'=47 printfr(%d/n,'-','-','-','-','/','/','/'); o/p =? 12.o/p=? int i; i=1; i=i+2*i++; printf(%d,i); 8.{ ch='A'; while(ch<='F'){ switch(ch){ case'A':case'B':case'C':case'D':ch++;continue; case'E':case'F':ch++; } putchar(ch); } } a)ABCDEF b.EFG c.FG d.error 9. FILE *fp1,*fp2; fp1=fopen("one","w") fp2=fopen("one","w") fputc('A',fp1) fputc('B',fp2) fclose(fp1) fclose(fp2)} a.error b. c. d. 10. int a=1; b=2; c=3; *pointer; pointer=&c; a=c/*pointer; b=c; printf("a=%d b=%d",a,b); a. a=1 b=3 b a=3 b=3 c 3 2 d. error 11.#include<malloc.h> char *f() {char *s=malloc(8); strcpy(s,"goodbye")} main() { char *f()_; printf("%c",*f()='A'); o/p=? 13. int sum(n) int n; if(n<1)return n; else return(n+sum(n-1)) a 10 b 16 c 14 d 15 14. when a function is recursively called all , automatic variables are a. stored in stack b . c. d 15) #define MAN(x,y) (x)>(y)?(x):(y) { int i=10;j=5;k=0; k= MAN(i++,++j) printf(%d %d %d %d,i,j,k)} 16.what is o/p main() {int i=3; while(i--) { int i=100 i--; printf("%d..",i); } } a) infinite loop b) error c) 99..99..99..99 d) 3..22..1..

............................................. 17 what is the o/p of the program main() { int rows=3,colums=4; int a[rows][colums]={1,2,3,4,5,6,7,8,9,10,11,12}; i=j=k=99; for(i=0;i<rows;i++) for(j=0;j<colums;j++) if(a[k][j]<k) k=a[i][j]; printf("%d\n",k);

1. A SOLID ICE OF 11 X 8 X2 INCHES IS MADE INTO ROD OF DIA 4 INCH. WHAT IS THE LENGE OF ROD? ANS: 3.5 INCH 2. THERE WERE 750 PEOPLE WHEN THE FIRST SONG WAS SUNG. AFTER EACH SONG 50 PEOPLE ARE LEAVING THE HALL. HOWMANY SONGS ARE SUNG TO MAKE THEM ZERO? ANS:16 3. A PERSON IS CLIMBING OF 60 MTS . FOR EVERY MINUTE HE IS CLIMBING 6 MTS AND SLIPPING 4 MTS . AFTER HOWMANY MINUTES HE MAY REACH THE TOP? ANS: (60-6)/2 +1 :28 4. HOWMANY ZEROS ARE THERE IN THE PRODUCT OF THE INTEGER FROM 1TO 100?ANS: 24(NOT GIVEN) 1 TO 10 -2 ZEROS 21 TO 30 -3 ZEROS : BECAUSE 25 = 5*5 22 *5 24 *5 5. A CAN DO WORK IN 2 HOURS B CAN DO A WORK IN 3 HOURS WHAT IS THE SHORTEST TIME TYEY CAN FINISH THE WORK? ANS: 1HOUR 12 MIN. 6..SALARY IS INCREASED BY 1200 ,TAX IS DECREASED FROM 12% TO 10% BUT PAYING SAME AMOUNT AS TAX . WHAT IS THE PREVISIOUS SALARY? ANS:6000 7. THE LEAST NO. WHICH IS WHEN DEVIDED BY 4,6,7 LEAVES A REMAINDER OF 2 ? ANS: 86 8. A MAN DRIVING THE CAR AT TWICE THE SPEED OF AUTO ONEDAY HE WAS DRIVEN CAR FOR 10 MIN. AND CAR IS FAILED. HE LEFT THE CAR AND TOOK AUTO TO GOTO THE OFFICE . HE SPENT 30 MIN. IN THE AUTO. WHAT WILL BE THE TIME TAKE BY CAR TO GO OFFICE? ANS:25 MIN 9.A REPORT HS 20 WHEETS EACH OF 55 LINES AND EACH SUCH A LINE CONSISTS OF 65 CHARACTERS. IF THE REPORT HAS TO BE RETYPED WITH EACH SHEET HAVING 65 LINES AND EACH LINE HAVE 75 CHARACTERS,THE PERCENTAGE OF REDUCTION OF NO OF SHEETS IS CLOSEST IS TO? ANS: 25% 10. OUT OF 100 FAMILIES IN NEIGHBOUR HOOD , 55 OWN RADIO, 75 OWN T.V AND 25 OWN VCR. ONLY 10 FAMILIES HAVE ALLOF THESE, AND EACH VCR OWNER HAS TV . IF 25 FAMILIES HAVE THE RADIO ONLY, THE NO. OF FAMILIES HAVE ONLY TV ARE? ANS: 30 KYA KYA IS AN ISLAND IN THE SOUTH PACIFI . THE INHABITANTS OF KYA KYA ALWAYS ANSWER ANY QUESTION WITH TWO SENTENCES, ONE OR WHICH IS ALWAYS TRUE AND OTHER IS ALWAYS FALSE. 1. YOU ARE WALKING ON THE ROAD AND COME TO A FORK. YOU ASK ,THE INHABITANTS RAM.LAXMAN, AND LILA AS" WHICH ROAD WILL TAKE ME TO THE VILAGE? RAM SAYS: I NEVER SPEAK TO STRANGERS. IAM NEW TO THIS PLACE LAXMAN SAYS: IAM MARRIED TO.LILA. TAKE THE LEFT ROAD LILA SAYS: IAM MARRIED TO RAM. HE IS NOT NEW TO THIS PLACE ANS: LEFT ROAD TAKE YU TO THE VILLAGE 2. YOU FIND THAT YOUR BOAT IS STOLLEN. U QUESTIONED THREE INHABITANTS OT ISLANDS AND THEIR REPLIES ARE JOHN : I DIDNOT DO IT. MATHEW DIDNOT DO IT MATHEW : I DIDNOT DO IT. KRISHNA DIDNOT DO IT KRISHNA: I DID NOT DO IT; I DONOT KNOW WHO DID IT ANS: MATHEW STOLEN THE BOAT 3. YOU WANT TO SPEAK TO THE CHIEF OF VILLAGE , U ASK THREE FELLOWS AMAR BOBBY, CHARLES AND BOBBY IS WEARING RED SHIRT AMAR : IAM NOT BOBBY`S SON ; THE CHIEF WEARS RED SHIRT BOBBY : IAM AMARS FATHER ; CHARLES IS THE CHIEF CHARLES : THE CHIEF IS ONE AMONG US; IAM THE CHIEF ANS: BOBBY IS THE CHIEF 4. THERE IS ONLY OPNE POLOT IN THE VILLAGE(ISLAND). YOU INTERVIEWED THREEM MAN KOISK ,LORRY AND MISHRA U ALSO NOTICE THAT KOISK IS WEARING CAP. M SAYS : LARRY IS FATHER IN THE PILOT .LARRY IS NOT THE PRIESTS SON

KOISK LARRY

: IAM THE PRIEST ON THEIS ISLAND ONLY PRISTS CAN WEAR THE CAPS : IAM THE PRIEST SON . KOISK IS NOT THE PREST ANS : KOISK IS THE PILOT

1.

typedef struct{ char *; nodeptr next; } * nodeptr; what does nodeptr stand for? 2. supposing that why each integer occupies 4 bytes and each charactrer 1 byte , what is the output of the following programme? #include<stdio.h> main() { int a[] ={ 1,2,3,4,5,6,7}; char c[] = {' a','x','h','o','k'}; printf("%d\t %d ", (&a[3]-&a[0]),(&c[3]-&c[0])); } ans : 3 3 3. what is the output of the program? #include<stdio.h> main() {struct s1 {int i; }; struct s2 {int i; }; struct s1 st1; struct s2 st2; st1.i =5; st2 = st1; printf(" %d " , st2.i); } ans: nothing (error) expl: diff struct variables should not assigned using "=" operator. 4.what is the output of the program? #include<stdio.h> main() { int i,j; int mat[3][3] ={1,2,3,4,5,6,7,8,9}; for (i=2;i>=0;i--) for ( j=2;j>=0;j--) printf("%d" , *(*(mat+j)+i)); } ans : 9 6 3 8 5 2 7 4 1 5. fun(n); } int fun( int n) { int i; for(i=0;i<=n;i++) fun(n-i); printf(" well done"); } howmany times is the printf statement executed for n=10? ans: zero expl: Befire reaching to printf statement it will goes to infinite loop. ---------------------------------------------------------------------6.what is the output of the program? main() {struct emp{ char emp[]; int empno; float sal; };

struct emp member = { "TIGER"}; printf(" %d %f", member.empno,member.sal); ans: error. In struct variable emp[], we have to give array size. If array size given ans is 0, 0.00 7. output of the program? # define infiniteloop while(1) main() {infiniteloop; printf("DONE"); } ans: none expl: infiniteloop in main ends with ";" . so loop will not reach end; and the DONE also will not print. 8. output of the program? main() {int a=2, b=3; printf(" %d ", a+++b); } ans:5 expl: here it evaluates as a++ + b. 9. output of the program? #define prn(a) printf("%d",a) #define print(a,b,c) prn(a), prn(b), prn(c) #define max(a,b) (a<b)? b:a main() { int x=1, y=2; print(max(x++,y),x,y); print(max(x++,y),x,y); } ans: 3 4 2 10. which of the following is the correct declaration for the function main() ? ans: main( int , char *[]) 11. if ptr is defined as int *ptr[][100]; which of the following correctly allocates memory for ptr? ans: ptr = (int *)(malloc(100* sizeof(int)); --------------------------------------------------------------SECTION-A you should write the programs for the following problems in C. 1. swapping two variables x,y without using a temporary variable. 2. a program has been given asking to find the output ans. it is algorithm for finding G.C.D 3. write a program for reversing the given string. 4. the integers from 1 to n are stored in an array in a random fashion. but one integer is missing. write a program to find the missing integer. ans. idea. the sum of n natural numbers is = n(n+1)/2. if we subtract the above sum from the sum of all the numbers in the array , the result is nothing but the missing number. 5. some bit type of questions has been given on pointers asking to to find whether it is correct from syntax point of view. and if it is correct explain what it will do.(around 15 bits). SECTION-B 6. write a c program to find whether a stack is progressing in forward or reverse direction. 7. write a c program that reverses the linked list. 8. ONE RECTANGULAR PLATE WITH LENGTH 8INCHES,BREADTH 11 INCHES AND 2 INCHES THICKNESS
IS THERE.WHAT IS THE LENGTH OF THE CIRCULAR ROD WITH DIAMETER 8 INCHES AND EQUAL TO VOLUME OF RECTANGULAR PLATE? ANS: 3.5INCHES 9 WHAT IS THE NUMBER OF ZEROS AT THE END OF THE PRODUCT OF THE NUMBERS FROM 1 TO 100

10 in some game 139 members have participated every time one fellow will get bye what is the number of matches to choose the champion to be held? ans: 138 11 one fast typist type some matter in 2hr and another slow typist type the same matter in 3hr. if both do combinely in how much time they will finish. ans: 1hr 12min 12 in 8*8 chess board what is the total number of squares refer odel ans:204 13 falling height is proportional to square of the time. one object falls 64cm in 2sec than in 6sec from how much height the object will fall. 14 gavaskar average in first 50 innings was 50 . after the 51st innings his average was 51 how many runs he made in the 51st innings 15 2 oranges,3 bananas and 4 apples cost Rs.15 . 3 ornages 2 bananas 1 apple costs Rs 10. what is the cost of 3 oranges, 3 bananas and 3 apples ANs Rs 15. 16 in 80 coins one coin is counterfiet what is minimum number of weighings to find out counterfiet coin 18.the function strcmp(str1,str2) returns ans: int 19. int *x[](); means expl: Elments of an array can't be functions. 20.#define PRINT(int) printf("int=%d",int); main() {int x,y,z; x=03;y=-1;z=01; PRINT(x^x); z<<=3;PRINT(x); ----> I think here may be (z). for this ans=8. if (x) ans ix =3. y>>=3;PRINT(y); } expl: 0,8,-1 (if second is z) 21. struct list{ int x; struct list *next; }*head; the struct head.x =100 above is correct / wrong expl: Before using the ptr type struct variable we have to give memory to that .And also when ever the struct variable is ptr then we access the members by "->" operator. 22. '-'=45 '/'=47 printfr(%d/n,'-','-','-','-','/','/','/'); o/p =? ans: 45 ( i.e it takes first argument in Printf function. 23.o/p=? int i; i=1; i=i+2*i++; printf(%d,i);

ans: 4

24.{ ch='A'; while(ch<='F'){ switch(ch){ case'A':case'B':case'C':case'D':ch++;continue; case'E':case'F':ch++; } putchar(ch); } } a)ABCDEF b.EFG c.FG d.error 25. FILE *fp1,*fp2;

ans: c

fp1=fopen("one","w") fp2=fopen("one","w") fputc('A',fp1) fputc('B',fp2) fclose(fp1) fclose(fp2)} a.error b. c. d.

ans: no error. But It will over writes on same file.

26. int a=1, b=2, c=3, *pointer; pointer=&c; a=c/*pointer; b=c; printf("a=%d b=%d",a,b); a. a=1 b=3 b a=3 b=3 c 3 2 d. error ans:d.Because ";"indicates competion of that statement.soIt give eror. * Imp: And in above program " a=c/*pointer " statement it considering as starting of comment statement. So , It also causing for syntax error. 27.#include<malloc.h> char *f() {char *s=malloc(8); strcpy(s,"goodbye")} main() {char *f(); printf("%c",*f()='A'); } o/p=? ans: prints " A " 28. int sum(n) int n; if(n<1)return n; else return(n+sum(n-1)) a 10 b 16 c 14 d 15 ans: If we take n=5 then ans is 15. 29. when a function is recursively called all , automatic variables are a. stored in stack b . c. d ans: (a) 30) #define MAN(x,y) (x)>(y)?(x):(y) { int i=10;j=5;k=0; k= MAX(i++,++j) printf(%d %d %d %d,i,j,k)} 31) a=10;b=5; c=3;d=3; if(a<b)&&(c=d++) printf(%d %d %d %d a,b,c,d) else printf("%d %d %d %d a,b,c,d); 32. what is o/p #include<stdarg.h> show(int t,va_list ptr1) { int a,x,i; a=va_arg(ptr1,int) printf("\n %d",a) } display(char) {int x; listptr; va_star(otr,s);

n=va_arg(ptr,int); show(x,ptr); } main() { display("hello",4,12,13,14,44); } a) 13 b) 12 c) 44 d) 14 33. if the following program (my prog) main(int size of ,char *arg[]) { while(size of arg) printf("%s",arg[--size of arg) } is run from the command line as myprog jan feb mar apr what would be the o/p a)myprog jan,feb,mar,apr b)rev c)jan,feb,mar,apr d)error 34.what is o/p main() {int i=3; while(i--) { int i=100 i--; printf("%d..",i); } } a) infinite loop b) error c) 99..99..99..99 d) 3..22..1.. 35)what is the o/p of the program main() { int rows=3,colums=4; int a[rows][colums]={1,2,3,4,5,6,7,8,9,10,11,12}; i=j=k=99; for(i=0;i<rows;i++) for(j=0;j<colums;j++) if(a[k][j]<k) k=a[i][j]; printf("%d\n",k); ........................................................ APTITUDE TEST 1)33 1/3 of 101 + 296 is (ans 1200) check 2)0.625= ? (ans 27/40) 3)One ship goes along the stream direction 28 km and in opposite direction 13 km in 5 hrs for each direction.What is the velocity of stream? (ans 1.5 kmph) 4)Cubic root of 3375=? (ans 15) 5)2020201-565656=? (ans 1454545) 6)CHAIRS PROBLEM 5 chairs=9 tables,12 tables = 7 stools likethat- - - (ans is 80Rs) 7)One clock ringes 7 O'clock in 7 sec.In how many seconds it will

ring 10 O'clock. (ans 10.5 sec) 8)One watch is showing 30 past 3 .What is the angle between minutes & hours hand? (ans 75 degrees) 9)The average of 4 consecutive even numbers is 27. What is the largest number? (ans 30) 10) 25 stations ,24 stations are inbetween- - - - how many tickets should be required. (ans 25*24=600)PUZZLES TO PUZZLE YOU "S.DEVI"PROB 24 11)One ball was dropped from 8ft height and every time it goes half of the height.How much distance it will travell before coming to rest. (ans 24) 12)Two trains are travelline at equilateral .Train A is travelling in the direction of earths spin.Other train B is travelling in opposite direction of earths spin.Which trains wheels will wear first?and why? (ans TRAIN B .Because of less centrifugal force.) C QUESTIONS:WHAT IS THE OUT PUT FOR FOLLOWING PROGRAMMS 1)main() { char a[2]; *a[0]=7; *a[1]=5; printf("%d",&a[1]-a) ANS: ans may be 1.(illegal initialization) 2) #include<stdio.h> main(){ char a[]="hellow"; char *b="hellow"; char c[5]="hellow"; printf("%s %s %s ",a,b,c); printf(" ",sizeof(a),sizeof(b),sizeof(c)); } (ans is hellow,hellow,hellow 6,2,5 ) 3) #include<stdio.h> main() float value=10.00; printf("%g %0.2g %0.4g %f",value,value,value,value) } (ans is 10,10,10,10.000000) 4) #include<stdio.h> void function1; int i-value=100; main() { i-value=50; function1; printf("i-value in the function=",i-value); printf("i-value after the function=",i-value); } printf("i-value at the end of main=",i-value); functioni() i-value=25; THIS IS ROUGH IDEA OF THE PROGRAM

ANS ARE 1)i-value in the function=25; 2)i-value after the function=50; 3)i-value at the end of the main=100; 5) main() {funct(int n); { switch(n) case1: m=2;break; case2: m=5; break; case3: m=7; break; default: m=0; } THIS IS ROUGH IDEA: (ANS:Out put is m=0) IN INTERVIEW THEY ASKED 1)TELL ABOUT YOUR PROJECT (and asked very few Q's on project.But usually askes lot of Q's) 2)WHY YOU CHOOSE FEM AS YOUR PROJECT ? Because of my guide active guidancy. 3)TELL ABOUT YOUR SELF? 4)YOU GOT GOOD MARKS IN APTITUDE?WHECH STEPS YOU HAVE TAKEN FOR IMPROVING APTITUDE? (I have subscribied C S R & READERS DIGEST) 5)DO YOU KNOW C? yes I know C & C++ 6) WHAT IS OBJECT? 7) WHAT IS CLASS? 8)WHAT IS INHERATANCY.EXPLAIN THE NEED? 9)WHAT IS POLYMORPHISM.EXPLAIN WITH EXAMPLE? 10)DO YOU EXPERT IN C? NO 11) DO YOU EXPERT IN POINTERS? No.But I can tell you what I know. 12)WHAT DO YOU MEEN char ****a? 13) WHAT IS b=&a? 14)TELL ME ABOUT PRE-PROCESSORS? 15)WHAT DO YOU KNOW ABOUT OUR COMPANY? 16)ANY FRIENDS OF YOU ARE THERE IN WIPRO? 17)WHAT THEY TOLD ABOUT US? 18)ANY QUESTIONS PLEASE ? BE CONFIDENT AND ALWAYS WITH SMILE IN INTERVIEW. There are 15 c q's all are discriptive. 1)fallacy f() { int a; void c;f2(&c,&a); 2)a=0; b=(a=0)?2:3; a) What will be the value of b? why b) If in 1st stmt a=0 is replaced by -1, b=? c) If in second stmt a=0 is replaced by -1, b=? 3)char *a[2] int const *p; int *const p; struct new { int a;int b; *var[5] (struct new) 4)f() {int a=2; f1(a++); }

f1(int c) {printf("%d", c); }c=? 5)f1() {f(3);} f(int t) { switch(t); { case 2: c=3; case 3: c=4; case 4: c=5; case 5: c=6; default: c=0;} value of c? 6)Fallacy int *f1() { int a=5; return &a; } f() int *b=f1() int c=*b; } 7)a)Function returning an int pointer b)Function ptr returning an int ptr c)Function ptr returning an array of integers d)array of function ptr returning an array of integers (See Scham series book) 8)fallacy int a; short b; b=a; 9)Define function ?Explain about arguments? 10)C passes By value or By reference? 11)Post processed code for abc=1; b=abc1; (1 or 2 blank lines are given) strcpy(s,"abc"); z=abc; 12)difference between my-strcpy and strcpy ?check 13)f() { int *b; *b=2; } 14)Function which gives a pointer to a binary trees const an integer value at each code, return function of all the nodes in binary tree.(Study)Check 15)Calling refernce draw the diagram of function stack illustrating the variables in the -----then were pushed on the stack at the point when function f2 has been introduced type def struct { double x,double y} point; main( int argc, char *arg[3]) {double a; int b,c; f1(a,b);} f1(double x, int y)

{ point p; stack int n; f2(p,x,y)} f2(point p, double angle) { int i,j,k,int max) }_________________________________________________________ 1)Least no. when divide by [7 gives remainder 6,6gives 5,5 gives 4 and soon ans;419 2)What compilation do (ans source code to obj) 3)Artficial language is provided which of the language (Lisp) check 4)241 change its equivalent octal ? 5)for cube and sphere 3 views are similarly draw one such figure? 6)Write a program to exchange two variaables without temp 7)Fortran cannot have value by reference 8)4,6,8,__ 9)success is to failure, joy is to 10)MEANING OF JOLLY? 11)opposite to essential? 12)"Raw" means 13)To be good "Wrestler " one should have? 14)"Command" opposite? 15)genuine opposite? 16)Two proverbs are goven 17)Sum of two consecutive nos is 55, larger one is? 18)A person goes 4/5 of his usual speed reaches 10min lateto his destinaton, time taken? 19)80% pass in english, 70%pass in maths , 10%fail in both , 144 pass in both . How many all appeared to the test? 20)To get a parabola if you cut a section of? 21)Bird is flying 120km/hr b/w B to R. two trians at B to R at 60 kmph The distance trvelled by the bird before it is killed.Ans.120 22)meaning of inert I Test Some of the questions what I have Iam sending. 1. 5,5,,13,13,21,21 Ans: 29 2.0,7,26,63,124, Ans: 215 i.e.n**3-1 rule following 3. 1,3,5,7, Ans: 9 '1' is not a prime number 4. If a person walks at 4/5th of his usual spee he reaches 40min late. If he walks athis usual speed how much time does he travels.Ans:160min or 2hr 40min 5. Two trains A&B start at opposite points 120km at 60kmph. A fly starting along with train A at 120kmph reaches B then returns back to touch and continue. By the time two trains meet howmuch distance the fly would have travelled? Ans : By 1hour both trains meet, so the distance travel by fly in 1hr is 120km. 6.In a class 80% have passed english,70% passed Hindi 10% didnot passed either. If 144 students passed both. What is the total strength of the class. Ans: 240 7. Find the least number when divided by 7 gives the reminder 6, when divided by 6 gives reminder 5, when divided by 5 gives reminder 4 and so on.... Ans: 419 8. If a man stands in front of sun what is the first letter of the direction which is left to him: Ans: North(N) 9.A square is to circle what is cube to Ans: sphere 10. Synonyms i) Joy = gay ii) Inert = Inactive 11.One wordswill begiven find oddman out: Ans:sickle like that a) sow b) cut c) d) sickel 12. If I bought a cycle before 2days of my birthday and I broke it after 3 days of my birthday the day I broke is Mar2, 1956? Answer following

logical questions? i) when is his birthday? Ans: April,28 (due to leap year i.e.1956) but do not keep answer blindly we just think before choosing answer Iam just giving ideaof question 13. Monday Aug25, 96 Mr A, You forgott your umbrella during the party on last friday.I expected you to collect it on your visit on wednesday,I plan to leave on this Friday. Questions: when A missed umbrella? When A is supposed to collect it? When K leaves? Hint: These dates i.e. Aug 25 is not exactly given in test, but Iam giving feel of that question.If you solve this question you can solve it easily in exam. 14.What is my father's sons son to my son? Ans: cousin brother 15.On cutting which solid parabola would be generated Ans: cone 16. Eulers formula: Ans: F+V-E =2; F= faces;V= vertices;E = number of edges 17. Newton Rapson method is to find Ans:to find the root of f(x) = 0; 18. How many tangents can be dran within three circles if they donot lie within each other Ans : 12 But this answer is not there I kept 8 as answer 19. In language the fortran which is true. A) fortran uses call by value 20. When a program is compiled what it produces Ans:source code to object code 21. In the following venn diagram shaded region is represented by some question like that I can't draw figure here thats why Iam sendinganswer only Ans: (B-A)' i.e. (B-A) whole dash 22. xy-x+2y = 6 equation is shifted to form equation xy=c what is c? Ans : 4 23.When x is real what is the least value of (x**2-6*x+5)/(x**2+2*x+1) Ans:-1/3 24.When an object like cube or sphere is seen along x,y,z,axes we get the same.Apart from these suggest another which has similar characteristics? Ans:you have to draw the figure Ans: is triangular prism you draw triangular prism. 25. When an object is seen from front side we can see two concentric squares and top view also without any hidden lines. Draw the side view. Ans: I know ans but I canot draw. 26. Convert 251 decimal to base 8(i.e. octal)? Ans: similar question but for this question answer is 373 27.How much information can be solved in 1 byte of a IBM pc compatible? Ans: 256 28.What is the language used for Artificial Intelligence Ans: lisp 29. Swap two variables without using temporary variableAns: a= a+b; b= a-b; a= a-b: 30.Which is not the operating system ? Ans: BIOS 31. What is the optimum number of operations for 2*(x**3)+3*(x**2)+5*x+5? Ans: three multiplications, three additions. 32. A=> Bmeans Ans: if A is true B has to be true 33.If A is not invertible and BA = I is not possible Ans: Determinant is Zero. 34, What is FREE BoDY Diagram Ans: Used for analysing FEM. 35. A die is thrown twice what is the probability that you get same number Ans:11/36. Section-I 1). Piggy backing is a technique for a) Flow control b) sequence c) Acknowledgement d) retransmition ans: c piggy backing 2). The layer in the OST model handles terminal emulation

a) session b) application c) presentation d) transport ans: b application 3) ans: a odd numbers of errors 4)Q. In signed magnitude notation what is the minimum value that can be represented with 8 bits a) -128 b) -255 c) -127 d) 0 5)Q. there is an employer table with key feilds as employer no. data in every n'th row are needed for a simple following queries will get required results. a) select A employe no. from employe A , where exists from employe B where A employe no. >= B employe having (count(*) mod n)=0 b) select employe no. from employe A, employe B where A employe no. >= B employ no. grouply employe no. having (count(*) mod n=0 ) c) both a& b d)none of the above 6)Q. type duplicates of a row in a table customer with non uniform key feild customer no. you can see a) delete from costomer where customer no. exists ( select distinct customer no. from customer having count ) b) delete customer a where customer no. in (select customer b where custermer no. equal to b custemor no. ) and a rowid > b rowid c) delete customer a where custermor no. in ( select customer no. from customer a, customer b ) d) none of the above SECTION-II 1) long int size a) 4 bytes b) 2 bytes c) compiler dependent d) 8 bytes ans: compiler dependent note: order of a,b,c,d are doubt but answer is correct. 2) x=2,y=6,z=6 x=y==z; printf(%d",x) PART 1 1). A beggr collects cigarette stubs and makes one ful cigarette with every 7 stubs. Once he gets 49 stubs . How many cigarettes can he smoke totally. Ans. 8 2). A soldiar looses his way in a thick jungle at random walks from his camp but mathematically in an interestingg fashion. First he walks one mile east then half mile to north. Then 1/4 mile to west, then 1/8 mile to south and so on making a loop. Finally hoe far he is from his camp and in which direction. ans: in north and south directions 1/2 - 1/8 + 1/32 - 1/128 + 1/512 - and so on = 1/2/((1-(-1/4)) similarly in east and west directions 1- 1/4 + 1/16 - 1/64 + 1/256 and so on

= 1/(( 1- ( - 1/4)) add both the answers 3). hoe 1000000000 can be written as a product of two factors neither of them containing zeros Ans 2 power 9 x 5 ppower 9 ( check the answer ) 4). Conversation between two mathematcians: first : I have three childern. Thew pproduct of their ages is 36 . If you sum their ages . it is exactly same as my neighbour's door number on my left. The sacond mathematiciaan verfies the door number and says that the not sufficient . Then the first says " o.k one more clue is that my youngest is the youngest" Immmediately the second mathematician answers . Can you aanswer the questoion asked by the first mathematician? What are the childeren ages? ans 2 and 3 and 6 5). Light glows for every 13 seconds . How many times did it between 1:57:58 and 3:20:47 am ans : 383 + 1 = 384 6). 500 men are arranged in an array of 10 rows and 50 columns . ALL tallest among each row aare asked to fall out . And the shortest among THEM is A. Similarly after resuming that to their originaal podsitions that the shorteest among each column are asked to fall out. And the longest among them is B . Now who is taller among A and B ? ans A 7). A person spending out 1/3 for cloths , 1/5 of the remsaining for food and 1/4 of the remaining for travelles is left with Rs 100/- . How he had in the begining ? ans RS 250/8). there are six boxes containing 5 , 7 , 14 , 16 , 18 , 29 balls of either red or blue in colour. Some boxes contain only red balls and others contain only blue . One sales man sold one box out of them and then he says " I have the same number of red balls left out as that of blue ". Which box is the one he solds out ? Ans : total no of balls = 89 and (89-29 /2 = 60/2 = 30 and also 14 + 16 = 5 + 7 + 18 = 30 9). A chain is broken into three pieces of equal lenths conttaining 3 links each. It is taken to a backsmith to join into a single continuous one . How many links are to tobe opened to make it ? Ans : 2. 10). Grass in lawn grows equally thickand in a uniform rate. It takes 24 days for 70 cows and 60 for 30 cows . How many cows can eat away the same in 96 days.? Ans : 18 or 19

11). There is a certain four digit number whose fourth digit twise the first digit. Third digit is three more than second digit. Sum of the first and fourth digits twise the third number. What was that number ? Ans : 2034 and 4368

is

If you qualify in the first part then you have to appear for the second i.e the following part. Part 2. 1. From a vessel on the first day, 1/3rd of the liquid evaporates. On the second day 3/4th of the remaining liquid evaporates. what fraction of the volume is present at the end of the II day. 2. an orange galss has orange juice. and white glass has apple juice. Bothe equal volume 50ml of the orange juice is taken and poured into the apple juice. 50ml from the white glass is poured into the orange glass. Of the two quantities, the amount of apple juice in the orange glass and the amount of orange juice in the white glass, which one is greater and by how much? 3. there is a 4 inch cube painted on all sides. this is cut into no of 1 inch cubes. what is the no of cubes which have no pointed sides. 4. sam and mala have a conversation. sam says i am vertainly not over 40. mala says i am 38 and you are atleast 5 years older than me. Now sam says you are atleast 39. all the sattements by the two are false. How hold are they realy. 5. ram singh goes to his office in the city, every day from his suburbun house. his driver mangaram drops him at the railway station in the morning and picks him up in the evening. Every evening ram singh reaches the station at 5 o'clock. mangaram also reaches at the same time. one day ramsingh started early from his office and came to the station at 4 o'clock. not wanting to wait for the car he starts walking home. Mangaram starts at normal time, picks him up on the way and takes him back house, half an hour early. how much time did ram singh walk. 6. in a railway station, there are tow trains going. One in the harbour line and one in the main line, each having a frequency of 10 minutes. the main line service starts at 5 o'clock. the harbour line starts at 5.02a.m. a man goes to the station every day to catch the first train. what is the probability of man catchinhg the first train 7. some people went for vaction. unfortunately it rained for 13 days when they were there. but whenever it rained in the morning, they had clean afternood and vice versa. In all they enjoyed 11 morning and 12 afternoons. how many days did they stay there totally 8. exalator problem repeat 9. a survey was taken among 100 people to firn their preference of watching t.v. programmes. there are 3 channels. given no of people who watch

at least channel 1 " " 2 " " 3 no channels at all atleast channels 1and 3 " " 1 and 2

" " 2 and 3 find the no of people who watched all three. 10. albert and fernandes they have two leg swimming race. both start from opposite and of the pool. On the first leg, the boys pass each other at 18 mt from the deep end of the pool. during the II leg they pass at 10 mt from the shallow end of the pool. Both go at const speed. but one of them is faster. each boy rests for 4 sec to see at the end of the i leg. what is the length of the pool. 11. T H I S Each alphabet stands for one I S digit, what is the maximum value T -------------can take X F X X X X U X -------------X X N X X -------------1. an escalator is descending at constant speed. A walks down and takes 50 steps to reach the bottom. B runs down and takes 90 steps in the same time as A takes 10 steps. how many steps are visible when the escalator is not operating. 2. evvery day a cyclist meets a train at a particular crossing. the road is straignt before the crossing and both are travelling in the same direction. cyclist travels with a speed of 10 Kmph. One day the cyclist comes late by 25 min. and meets the train 5km before the crossing. what is the seppd of the train. 3. five persons muckerjee, misra, iyer, patil and sharma, all take then first or middle names in the full names. There are 4 persons having I or middle name of kumar, 3 persons with mohan, 2 persons withdev and 1 anil. --Either mukherjee and patil have a I or middle name of dev or misra and iyer have their I or middle name of dev --of mukherkjee and misre, either both of them have a first or middle name of mohan or neither have a first or middle name of mohan --either iyer of sharma has a I or middle name of kumar hut not both. who has the I or middle name of anil 4. reading conprehension 5. a bird keeper has got Ppigeon, M mynas and S sparrows. the keeper goes for lunch leaving his assistant to watch the birds. a. suppose p=10, m=5, s=8 when the bird keeper comes back, the assistant informs the x birds have escaped. the bird keeper exclaims oh no! all my sparrows are gone. how many birds flew away. b. when the bird keeper come back, the assistand told him that x birds have escaped. the keeper realised that atleast2 sparrows have escaped. what is minimum no of birds that can escape. 6. select from the five alternatives A,B,C,D,E AT THE end of each question ,two conditions will be given. the choices are to filled at follows. a. b. c. d. if if if if a a a a definete definete definete definete conclusion conclusion conclusion conclusion can can can can be be be be drawn drawn drawn drawn from from from from condition condition condition condition 1 2 1 and 2 1 or 2

e. no conclusion can be drawn using both conditions 1. person 1 says N<5 person says n>5 person 3 says 3N>20 person 4 says 3n>10 person 5 says N<8 whaT IS value of N a) 1. no of persons who speak false being less than no of persons who tells the truth. 2. person 2 is telling the truth. b) 1. no of persong telling the truth is greater than no of persons telling lies 2. person 5 is telling the truth. 7. there are N coins on a table. there are two players A&B. you can take 1 or 2 coins at a time. the person who takes the last coin is the loser. a always starts first --1. if N=7 a) A can always win by taking two coins in his first chanse b) B can win only if A takes two coins in his first chance. c) B can always win by proper play d) none of the above --2. A can win by proper play if N is equal to a) 13 b) 37 c) 22 d) 34 e) 48 ans. e. --3. B can win by proper play if N is equal to a) 25 b)26 c) 32 d) 41 e) none --4. if N<4, can A win by proper play always 8. Two turns have vertain pecular charcteristics. One of them always lies on Monday, Wednesday, Friday. \the other always lies on Tuesdays, thursdays and saturdays. On the other days they tel the truth. You are given a conversation. person A-- today is sunday my name is anil person B-- today is tuesday, my name is bill --------------------------------------------------------------1) There are two balls touching each other circumferencically. The radius of the big ball is 4 times the diameter of the small ball.The outer small ball rotates in anticlockwise direction circumferencically over the bigger one at the rate of 16 rev/sec. The bigger wheel also rotates anticlockwise at Nrev/sec. what is 'N' for the horizontal line from the centre of small wheel always is horizontal. 2) 1 2 3 4 + 3 4 5 5 ---------4 6 8 9 - 2 3 4 5 ---------2 3 4 4 + 1 2 5 4 -----------3 6 9 8

Q) Strike off any digit from each number in seven rows (need not be at same place) and combine the same operations with 3 digit numbers

to get the same addition. After this strike off another digit from all and add all the No.s to get the same 2 digit No. perform the same process again with 1 digit No.s. Give the ' no.s in 7 rows at each stage. 3) there is a safe with a 5 digit No. The 4th digit is 4 greater than second digit, while 3rd digit is 3 less than 2nd digit. The 1st digit is thrice the last digit. There are 3 pairs whose sum is 11. Find the number. Ans) 65292. 4) there are 2 guards Bal and Pal walking on the side of a wall of a wearhouse(12m X 11m) in opposite directions. They meet at a point and Bal says to Pal " See you again in the other side". After a few moments of walking Bal decides to go back for a smoke but he changes his direction again to his previous one after 10 minutes of walking in the other(opposite) direction remembering that Pal will be waiting for to meet.If Bal and Pal walk 8 and 11 feet respectively, how much distance they would have travelled before meeting again. 5) xxx)xxxxx(xxx 3xx ------xxx x3x -----xxx 3xx ------

Q) Find the 5 digit No. Hint: 5 is used atleast once in the calculation. 6) Afly is there 1 feet below the ceiling right across a wall length is 30m at equal distance from both the ends. There is a spider 1 feet above floor right across the long wall eqidistant from both the ends. If the width of the room is 12m and 12m, what distance is to be travelled by the spider to catch the fly? if it takes the shortest path. 7) Ramesh sit around a round table with some other men. He has one rupee more than his right person and this person in turn has 1 rupee more than the person to his right and so on, Ramesh decided to give 1 rupee to his right & he in turn 2 rupees to his right and 3 rupees to his right & so on. This process went on till a person has 'no money' to give to his right. At this time he has 4 times the money to his right person. How many men are there along with Ramesh and what is the money with poorest fellow. 8)Question related to probabilities of removing the red ball from a basket,given that two balls are removed from the basket and the other ball is red. The basket contains blue,red,yellow balls. 9)Venkat has 1boy&2daughters.The product of these children age is 72. The sum of their ages give the door numberof Venkat.Boy is elder of three.Can you tell the ages of all the three.

ANALYTICAL ---------1)L:says all of my other 4 friends have money M:says that P said that exact one has money N:says that L said that precisely two have money O:says that M said that 3 of others have money. P:Land N said that they have money. all are liers.Who has money&who doesn't have? 2)A hotel has two,the east wing and the west wing.some east wing rooms but not all have an ocean view(OV).All WW have a harbour view(HV).The charge for all rooms is identical, except as follows * Extra charge for all HV rooms on or above the 3rd floor * Extra charge for all OV rooms except those without balcony * Extra charge for some HV rooms on the first two floor&some EW rooms without OV but having kitchen facilities. (GRE modrl Test 3-question 1J-22) 3)Post man has a data of name surname door no.pet name of 4 families. But only one is correct for each family.There are a set of statements &questions. 4)4 couples have a party.Depending on the set of statements,find who insulted whom and who is the host of the party. 5)5 women given some of their heights(tall,medium,short)Hair( long, plainted),stards(Black or Brown), sari,2 medium,2-short.Tall->no sari.Plainted->medium.Answer the combinations. 1) A person has to go both Northwards&Southwards in search of a job. He decides to go by the first train he encounters.There are trains for every 15 min both southwards and northwards.First train towards south is at 6:00 A.M. and that towards North is at 6:10 .If the person arrives at any random time,what is the probability that he gets into a train towards North. 2) A person has his own coach&whenever he goes to railway station he takes his coach.One day he was supposed to reach the railway station at 5 O'clock.But he finished his work early and reached at 3 O'clock. Then he rung up his residence and asked to send the coach immediately. He came to know that the coach has left just now to tje railway station. He thought that the coach has left just now to the railway station.He thought that he should not waste his time and started moving towards his residence at the speed of 3mi/hr.On the way,he gets the coach and reaches home at 6 o'clock.How far is his residence from railway station. 3)Radha,Geeta&Revathi went for a picnic.After a few days they forgot the date,day and month on which they went to picnic.Radha said that it was onThursday,May 8 and Geeta said that it was Thursday May 10.Revathi said Friday Jun 8.Now one of them told all things wrongly,others one thing wrong and the last two things wrongly.If April 1st is tuesday what is the right day,date and month? -------------------------------------------------------------1)At 6'o clock clock ticks 6 times. The time between first and last ticks was 30sec. How much time it takes at 12'o clock. Ans. 66 sec. 2 marks.

2)Three friends divided some bullets equally. After all of them shot 4 bullets the total no.of remaining bullets is equal to that of one has after division. Find the original number divided. Ans. x x-4 3x-12 = x x= 6 ans is 18 x x-4 x x-4 2 marks

3)A ship went on a voyage after 180 miles a plane statrted with 10 times speed that of the ship. Find the distance when they meet from starting point. Ans. 180 + (x/10) = x x = 20 ans is 180+20=200miles.

2 marks

4) Fill the empty slots. Three FOOTBALL teams are there. Given below the list of maches. A B C played 2 2 2 won 2 *0 *0 lost *0 *1 *1 draw *0 1 *1 Goals for *7 2 3 Goals against 1 4 7

the slots with stars are answers. 4 marks BC drew with 2-2 A won on B by 2-0 a won on C by 5-1 ( YOU HAVE TO FILL THE BLANKS AT APPROPRIATE STAR SYMBOLS.)` 5) There are 3 societies a,b,c. a lent tractors to b and c as many as they had. After some time b gave as many tractors to a and c as many as they have. After sometime c did the same thing. At the end of this transaction each one of them had 24. Find the tractors each orginally had. Ans a had 39, b had 21, c had 12, 4 marks

6) There N stations on a railroad. After adding x stations 46 additional tickets have to be printed. Find N and X. Ans. let N(N-1) = t; (N+x)(N+x-1) = t+46; trail and error method x=2

and N=11

4 marks

7)Given that April 1 is tuesday. a,b,c are 3 persons told that their farewell party was on a - may 8, thursday b - may 10,tuesday c - june 8, friday Out of a,b,c one is only correct one of the regarding month,day,date. Other told two correct and the third person told all wrong.What is correct date,month,day. 5 marks (ans may be MAY 10 SUNDAY. check once again

8)There are 4 parties. df,gs,dl(depositloss),ew ran for a contest. Anup,Sujit,John made the following statements regarding results. Anup said either df or ew will definitely win sujit said he is confident that df will not win John said he is confident that neither ew nor dl will win the result has come. only one of the above three has made a correct statement. Who has made the correct statement and who has won the contest. 5 marks. (ans DL ) 9)Five people a,b,c,d,e are related to each other. Four of them make one true statement each as follows. i) b is my father's brother. (ans. d said this) ii)e is my mother-in-law. ( b ) iii)c is my son-in-law's brother. ( e ) iv)a is my brother's wife. ( c ) who said each statement. 10 marks. 10) All members of d are also members of a All '' e '' d all '' c '' both a and b not all '' a are members of d not all '' d '' e Some questions on these conditions.(5questions 5 marks) 11) boys are allowed to watch football at c.v.Raman auditorium subjected to conditions. i)the boy over age 16 can wear overcoat ii)no boy over age 15 can wear cap iii)to watch the football either he has to wear overcoat or cap or both iv) a boy with an umberella or above 16 or both cannot wear sweater. v) boys must either not watch football or wear sweater. What is the appearence of the boy who is watching football. Try to solve this question................ -----------------------------------------------------------------------1) be * be = acb a,b,c,e are non zero numbers find b,e. ans) b=1 e=9 2) a,b,c,d,e are having numerical values. there are some conditions given a) a=c <===> b!=e b) difference between a and c as same as difference between c and b as same as difference between a and d c) c<a and c>d then find a,b,c,d,e 3) there are six cards in which it has two king cards. all cards are turned down and two cards are opened a) what is the possobility to get at least one king. b) what is the possibility to get two kings. 4) a person went to a shop and asked for change for 1.15paise.

but he said that he could not only give change for one rupee. but also for 50p,25p,10p and 5p. what were the coins he had ans) 1-->50 4--->10p 1--->25p

5) there are 3 nurses and they work altogether only once in a week. no nurse is called to work for 3 consecutive days. nurse 1 is off on tueseday,thursday and sunday. nurse 2 is off on saturday. nurse 3 is off on thursday,sunday. no two nurses are off more than once a week. find the day on which all the 3 nurses were on work. 6) there are 5 persons a,b,c,d,e and each is wearing a block or white cap on his head. a person can see the caps of the remaining 4 but can't see his own cap. a person wearing white says true and who wears block says false. i) a says i see 3 whites and 1 block ii) b says i see 4 blocks iii) e says i see 4 whites iiii) c says i see 3 blocks and 1 white. now find the caps weared by a,b,c,d and e 7) there are two women, kavitha and shamili and two males shyam, aravind who are musicians. out of these four one is a pianist, one flutist, violinist and drummer. i) across aravind beats pianist ii) across shyam is not a flutist iii) kavitha's left is a pianist iiii) shamili's left is not a drummer v) flutist and drummer are married. 8) 1/3 ed of the contents of a container evaporated on the 1 st day. 3/4 th of the remaining contents of the container evaporated the second day. what part of the contents of the container are left at the end of the second day. 9) a man covered 28 steps in 30 seconds but he decided to move fast and covered 34 steps in 18 seconds. how many steps are there on the escalator when stationary. 10) all fair skinned, rich, handsome, muscular, lean and employed are tall men 1) all lean men are muscular. 2) no fairskinned person who is not rich is handsome. 3) some muscular men are handsome. 4) all handsome are fairskinned. 5) no person who is neither fair skinned nor muscular is enplyed. 6) we unable to recall this condition and question also incomplete. -----------------------------------------------------------------------Part 1. -----(1) 9 cards are there. u have to arrange them in a 3*3 matrix. cards are of 4 colors.they are red,yellow,blue,green. conditions for arrangement: one red card must be in first row or second row.2 green cards should be in 3rd column.Yellow cards must be in the 3 corners only. Two blue cards must be in the 2nd row. Atleast one green card in each row. Solution: Yello Red Gren Blu Blu Gren

Yello Gren Yello 2. 4 cards are placed on a table, each card has two colors. U don't know the color of the back side of eachcard.4 persons A B C and D are sitting on the table before the cards. They can see Red, Green Red and blue .Out of the 4 poeple 2 always lie. They see the color on the reverse side and give the following comment A: Yello/green B: Neither Blue/nor Green c: Blue/Yello D: Blue/ Yello find out the color on the other side of the 4 cards. 3.Red and brown tribes [FROM BARRONS GRE] Conditions to get married with each other. 4. Venn diagram regarding Rich, muscular, soft-skinned, employed, etc.,( Refer BARRONS GRE GUIDE) -----------------------------------------------------------------------PART 2. ------1. SAKUNTALA DEVI'S PUZZLE BOOK : PUZZLES TO PUZZLE YOU. problem no: 3. ( Brothers and Sisters) A family I know has several children. Each boy in this family has as many sisters as brothers but each girl has twice as many brothers as sisters. How many brothers and sisters are there? ans: 4 boys and 3 girls. 2. No. of animals is 11 more than the no. of birds. If the no. of birds were the no. of animals and no. of animals were the no. of birds( ie., interchanging no.s of animals and birds.), the total no. of legs get reduced by one fifth (1/5). How many no. of birds and animals were there? ans: birds:11,animals:22 3. In a soap company a soap is manufactured with 11 parts. For making one soap you will get 1 part as scrap. At the end of the day u have 251 such scraps. From that how many soaps can be manufactured? ans: 22 + 2+ 1 = 25. 4. 2 * * | 3 * * | No. 7 does not occur in this ---------------| 5 * * | multiplication. * 4 * | * * 3 | Find the product. ---------------| * * * * * | ---------------| -------------------------------------------------ans 2 8 1 3 2 2 ----5 6 2 5 6 2 0 8 4 3 0 0

--------9 0 4 8 2 --------5. There is a 5digit no. 3 pairs of sum is eleven each. Last digit is 3 times the first one. 3 rd digit is 3 less than the second. 4 th digit is 4 more than the second one. Find the digit. ans : 25296. 6. There are five thieves, each loot a bakery one after the other such that the first one takes 1/2 of the total no. of the breads plus 1/2 of a bread. Similarly 2nd, 3rd,4th and 5fth also did the same. After the fifth one no. of breads remained are 3. Initially how many breads were there? ans : 31. 7.There are some chicken in a poultry. They are fed with corn One sack of corn will come for 9 days.The farmer decides to sell some chicken and wanted to hold 12 chicken with him. He cuts the feed by 10% and sack of corn comes for 30 days. So initially how many chicken are there? 8.Two people X & Y walk on the wall of a godown in opposite direction. They meet at a point on one side and then go ahead. X after walking for some time, walks in opposite direction for 15 mtrs.Then again he turns back and walks in the original direction. What distance did Y walk before they met again, if X walks 11 mtrs by the time Y walks 8 mtrs. ************************************************************************** Interview Practice ------------------------------------Practicing for the interview means practicing several behaviors - not just answering questions. You must dress well, watch your body language and posture, practice your manners and eye contact as well as practice answering questions correctly, smoothly, and with confidence. The practice questions below, in one form or another, account for a large percentage of interview questions. With each question, you are given a series of choices as to how you might answer the question. When you select an answer, you will learn whether your answer is correct-and why. Answering these questions will help you polish your interviewing techniques. The questions and answers in this excercise are generic and, in many cases, must be tailored to your individual situation. Still, the logic behind the answer remains essentially the same. Why are you the best person for the job? I 've held a lot of positions like this one, and that experience will help me here." "Because I am good at what I do." "Our discussion here leads me to believe this is a good place to work." "You need someone who can produce results, and my background and

experience are proof of my ability. For example..." If asked a point blank question such as: Are you creative? Are you analytical? Can you work under pressure? etc. What is the best way to answer? Answer yes or no. Answer yes and give a specific example. Answer yes and give an explanation.

3 Tell me about yourself. 1.Outline personal data, hobbies, and interests. 2.Give an overview of your personality and work habits. 3.Give three specific examples of your personality traits and accomplishments. 4. What was your CGPA? Why is it low? 1.My CGPA is -----. basically because I had a lot of fun in college. 2.My GPA is ----- because I held a full time job while in college, working my way through school. It is not relfective of my ability to do the job. 3.My GPA is ------ which I don't think is too low, at least compared to my friends. 5. What are you looking for in a position? 1."I'm looking for an opportunity to apply my skills and contribute to the growth of the company while helping create some advancement opportunities for myself." 2."I'm looking for an organization that will appreciate my contributions and reward my efforts." 3."I'm looking for a position that will allow me to make enough money to support my lifestyle. I am a hard worker and will give a concerted effort to earn the money I need." 6. What do you know about our organization? 1."I've done a little homework and here is what I know about your organization...(cite examples)" 2."Everything I've seen and heard makes me want to be a part of this organization. I understand your industry is ________ and your primary customer is __________. A particularly exciting part of your business appears to be _________ ."

3."I know enough to know this is an exciting place to work. It appears to be fit for my career goals." 7. What is a weakness? 1. I get really frustrated with my co-workers when they whine about everything. 2. I don't "toot my own horn". I like to go in and get the job done and I don't dwell on who gets credit. 3. I don't think I have a weakness.

8. How would you characterize your work style? 1. I am a very driven person. I make a list of what needs to be done and then tackle the items until I've completed the job. 2. I show up whenever I'm scheduled to work. 3.I haven't held a job yet so I don't know what my work style will be. 9. What are your strengths? 1."I am good at giving constructive criticism to my coworkers. This honesty is something I'm very proud of and have found essential to having open working relationships." 2."I consider myself to be very consistent. I have proven myself to be someone who can be counted upon to do what is expected." 3."I would have to chose between two skills. I am very proud of my determination and ability to get things done. At the same time, I am very proud of my analytical abilities and problem solving skills. These skills combine to give me a unique ability to solve problems and then implement the solutions." 10. How would co-workers describe you? 1."They perceive me as a leader. The people who have worked with me learned great deal and accomplished in many cases more than they thought possible." 2."My employees would tell you they got direction when they needed and the room to work when it was appropriate. I believe a measure of a good manager is how much he is able to get done through others." 3."They perceive me as someone who cared about them personally and had high expectations. I get a great deal of satisfaction from helping others do their best. My former employees would highlight three of my priorities which are to build loyalty and a team environment, obtain results and develop people."

11. What did you like and dislike about college? 1. I didn't like the tremendous ammount of homework some professors assigned us. I liked those professors who realized, I had a life outside of class. 2.I liked the opportunity to be involved on campus. It was a small campus that allowed students to take responsibility, organize events and be a part of the planning team. I can't really think of anything I disliked, college was a wonderful experience. 3.I liked having Wednesdays off. I think the thing I disliked most was living in the dorms.

12. Are you willing to relocate? 1.No. 2.I'm open to opportunities within the company so if that involves relocation I would consider it. 3.I'd move, but I know your headquarters is in Alaska and that's too cold for me. 13. What are your short term goals? 1."Short term, I just want a job." 2."Bills are beginning to pile up. In the short run I need to find work so I can keep up with my obligations." 3."Short-term, I'd like to find a position that is a good fit and where I can contribute to a company's bottom line. The position we are here to discuss today would appear to be such an opportunity. Could you tell me more about it?" 14. Where do you want to be in 5 years? 1.I haven't really thought that far ahead but I think I'd want your 2."If selected I would hope to meet my goals and take advantage of opportunitites to learn so I will be considered for other positions within the company. I hope to build my career with a company such as this one." 3."Long term, I hope to start my own business." 15. Describe a situation you've encountered with a difficult customer. 1.In my last job I dealt with customers at a retail store. One customer wanted to return an item she had obviously bought job.

several years ago, which was against store policy. I talked to her calmly and explained our policies and encouraged her to shop and I would exchange the item however I could not give a refund. 2. I rarely encounter a difficult customer because of my excellent customer service. 3. I had a customer once who claimed her steak was not cooked correctly....I picked up a knife and cut it open and explained that's the way it's supposed to be.

16. Before we go any further, what kind of money do you need to make? 1.I feel I am worth at least $30,000." 2."My salary requirements are negotiable. Your firm has a reputation of compensating employees fairly and I trust you would do the same in my case. I am very interested in finding the right opportunity and will be open to any fair offer when I do so." 3."Money is not very important to me. I need to be able to pay the bills but the work environment is far more important to me." Face to Face Interview Preparation So you have a job interview, NOW WHAT? You have sent out hundreds of resumes and finally a Human Resource person calls to schedule a time for you to come in for a face to face interview. This is a great company, and you think you are perfect for the job. Now, you must demonstrate that to the hiring authority you are perfect for the position. Here are some pointers to keep in mind when going in for the interview. Prepare - Do not go in attempting to "wing" it. Keep in mind there are lots of competitors for the job, and you will only have this opportunity to impress the hiring authority.Research and know the company, their history, products, services and reputation. Prepare answers to questions that will likely come up, like "What is your biggest weakness?" "What is your greatest failure?" "Describe your best and worse boss?" "Tell me something about yourself?" "Why did you leave your last job?" "How can you contribute to this company in this job?"

There will likely be a longer list of questions, each a potential landmine that can eliminate you from the competition. Keep your answers short and to the point. Do not ramble. Always be honest and avoid negative statements. Wear your best suit - The first impressions of a candidate are lasting. It is better to be over-dressed than under-dressed. Your appearance will demonstrate that you are taking the initiative. Go out of your way to make a good impression. Even if you never wear a suit to work, even if it is a production job, the interviewer will be pleased by your effort to impress. Be on time - It is better for you to be early and wait for your appointment time than to keep the interviewer waiting and wondering. If you miss your appointment time you may not get another. If a problem or emergency arises, and they do, call immediately and explain and offer to come in at another time, whenever is convenient for the interviewer.

Body language - Sit up, look attentive, do not cross your arms or legs make eye contact. Interviewers rely on body language to determine your level of interest. Present a positive attitude - Companies seek pleasant and positive people. Bring extra copies of your resume - You may interview with a team of people, do not make them share one resume. Avoid smoking and drinking alcohol before and during an interview. If going to lunch with an interviewer, decline alcholic beverages even if the interviewer orders a cocktail with their meal. If you are a smoker, abstain before and during the interview. Smoking can offend many people, even smoking before an interview can leave an odor which may be offensive to the interviewer. Do not lead with money or benefit questions in the initial interview - If your main motivation is money it will probably turn off most hiring authorities. Convince them you can do the job and want the job before discussing money and benefits. Money, benefits and vacation will come up and can be discussed should the company wish to make you an offer. Sell yourself - If you don't no one else will. Use facts and figures to quantify your experience and ability. Tell them the things that will benefit the company if they hire you. Show interest in the job - If you act cool they may not realize that you want the job. Companies want someone who is interested and enthusiastic about the job and the company. Don't make the hiring authority guess if you want the job. Do not close any doors - No matter what you see or hear during the interview don't overreact. Obstacles may come up regarding

money, relocation or other issues that can be resolved later if you leave the issue open. Getting an offer - If an offer is made to you during an interview never, reject it outright. Ask for time to think it over to consider money and the specific details of the offer. Always respond positively. If you let them know you want the job it will be a lot easier to negotiate items like salary later. When the Interview is over - Ask if there are any reservations about your ability to do the job. Deal with these now. Ask what is the next step in the interview process. If you like the job and want an offer now is the time to tell them. Do not assume they will know if you want the job or not. Follow-up - Be sure to send a note letting them know you appreciate the opportunity to interview and reiterating your interest in the position. Keep the note brief, and to the point.

1.In my last job I dealt with customers at a retail store. One customer wanted to return an item she had obviously bought several years ago, 2."If selected I would hope to meet my goals and take advantage of opportunitites to learn so I will be considered for other positions within the company. I hope to build my career with a company such as this one." 3."Long term, I hope to start my own business." 15. Describe a situation you've encountered with a difficult customer. Interview -tips ------------------------------1)You should do some rough work immediately adjacent to the problem(Aptitede) 2)You should write the explanationary notes adjacent to the C program. INTERVIEW AIM: 1)Project should be on FEM. 2)You have to explain project clearly 3)Don't tell "Iam expert in FEM or in C" Other wise they will ask more typical Ques. 4)You tell "I know C++ & C . I am learning C++ simultaneously with C." Q1)TELL ABOUT YOUR WORK (means project work) Q2)TELL ABOUT YOUR FAMILY Ans: Sir,I came from a family which gives higher

priority to education.We are two.Because of my parents active guidance we are pursuing higher studies.I sister studied Msc and she got married. I studied B.tech in N.U 10 in- - - INTER in - - - Q3)WHY YOU ARE COMING TO SOFT WARE? ANS:Well sir, What I have learned all these days definitely increased my technical skills.But a the same time also increased my ANALYTICAL,PROUBLE SHOOTING& PROBLEM SOLVING skills. What ever may be the technical backgrount ,above skills are necessary for S-W. Rapid grouth,frequent updating&Attractive compensation pay packages. Q4)WHAT IS YOUR AMBITION? ANS)Sir , I would like to become a person who is someone in SOFT WARE.

Q5)WHERE DO YOU LIKE TO SEE AFTER 5 YEARS? ANS:Sir One year from now I would like to become a good soft ware expert. Two years from now I would like to become a person who handles team work(i.e project leader) Five years from now I have to handle morethan one project at a time. Q6)WHY THIS COLLEGE? Sir, from the very first begining I have had special carving(interest) to pursue(get) my higher studies from any reputed institution.I hope I have succeeded. Q7)YOUR +POINTS ANS:I am a team person (you sould mension as captain of cricket) I can handle problems as they came Q8)YOUR -POINTS Sir I am a bit over confident(or emotional)and I believes people in first insident. Q9)IF YOU CAN'T SELECTED TO THIS JOB ,WHAT CAN YOU DO? ANS: Sir I am confident that I should definitely get job in your organization.I that worst case will happened I will try to rectify my errors and once again I will try for your organization. Even then if I failed , I will search for another organization which is suitable for my potential. Q10)WHY THIS COMPANY? ANS: Sir Iam looking in the company for the following things. 1)Which is a gaint in S-W.

2)Which is well reputed organization. 3)Which is having noninert enveronment I hope I will find all the above things in your organization. [1] Tell us about your work in brief. My Ans. Mention first the title, followed by a brief overview work, what we plan to achieve, what has been achieved so far, the relevance/scope of the work to the related area (i.e. how going to be useful). [ 5-10 mins. depending on interest of listener.] [2..n] Questions related to the work. Ans. Area dependent. [ ~ 10 mins ] [n+1] Tell us what you know about DMA and why that is needed? My Ans. As usual, mentioned the wastage of CPU computation power spent in busy-waiting. Told how DMA works. [n+2] What are the various types of scheduling algo, what is used by UNIX? My Ans. Mentioned Round Robin, First-come-first-served, Shortest-job-first, Earliest-deadline-first, Least-laxity-first, Priority-based-event-driven. UNIX uses RR with multi-level feedback. of the finally is it the

[n+3] How can you implement SJF in UNIX? My Ans. Usually, SJF means that we know the job-duration in advance. In UNIX where we cannot know that, we have to make assumptions about that based on which we should initially schedule. Periodically however, we have to fine-tune our initial assumptions based on the times taken by various ready jobs, and recompute estimates and change the schedule accordingly. [n+4] Different types of subroutine calling conventions? My Ans. Call by value, reference, value-result. [n+5] Parameter passing sequence used by C? My Ans. Rightmost parameter pushed first on stack. [n+6] What is a page-fault and how is it handled in UNIX? My Ans. [Refer to MJBach, Ch. 9 for details]. Personal questions in the first round -------------------------------------1. What was your overall position in the Univ. in B.E. 2. Anything you want to know about us. Technical Questions in the second round ---------------------------------------[1] What are the current trends and areas of focus in IT. My Ans. Talked about emerging trends of S/W Engg and ISO 9000 stuff (gave vague ideas about them as I don't know much nor do I care about these topics myself ;-)). Then mentioned the proliferation of O-O methodologies and their usefulness in speeding up development process,

code re-usability, ease of maintenance, ease of bug-fixing. Thirdly, mentioned the work going on in High-Speed N/w - FDDI, ATM, Fast-Ethernet(100Mbps). Told whatever little I knew about ATM in response to another question. [2] What is a Micro-Kernel architecture. My Ans. This is a developing area in OSs where instead of building the kernel as a single monolithic structure starting from scratch, it is built as a set of layers. The micro-kernel provides only the bare-bones like Device-drivers, rudimentary filesystem support etc. on which, depending on the intended area of application of the OS, it can be customized to provide various higher level OS features like Multiprocessing, IPC, etc. Personal Questions in the second round --------------------------------------1. Tell us about yourself, your background. 2. What does your father do currently. 3. Your performance in schooling, B.E. 4. Your +/- points. 5. Why do you think Wipro should take you. 6. What qualities do you have that make you a person suitable for going into the IT industry (a corollary to the previous question). 7. What do your friends opine about you. 8. When do you think you will complete and be able to join. 9. How can you assure that you will join by that time. 10. Anything you want to know about us. Company name: Wipro Infotech FIRST INTERVIEW:(First the interviewer asked me to name two favorite subjects - OS and Networks) a) Describe the memory management policies in Unix. How is paging implemented? How page faults are handled? Seems to be a favorite question for these chaps ---- Maurice Bach. b) Write a macro in C for swapping two nibbles in a byte. -Use the shift operators and be careful while defining temporary variables( if you do so) as you have to write a macro. Otherwise it is pretty simple. c) What is the CPU-scheduling policy in Unix? - Round robin scheduling with multilevel queues. d) Diffrence between short term, long term and medium term scheduler. -First two should be peaceful. The last one is also known as swapper. (See Taenenbaum and/or Peterson) e) Name various page-replacement policies. Which can be implemented both with and without pre-emption? - see Peterson. f) Describe the Sliding window protocol. What is it's advantage over stop-and-wait? - Saves bandwidth. (Taenenbaum please) 2ND INTERVIEW (Both personal and technical interleaved) a) Tell us something about yourself.

b) Aren't you going for higher studies abroad? Why? c) Rank, they wanted to know my approx position in my batch. d) What is re-entrant code? --- Non-self modifying code. Can be shared by many processes simultaneously. Gave e.g. of text-editors like 'vi'. Counter Q: But then no code modifies itself. What does 'non-self modifying' mean? ---- I don't know for sure. e) Diff between compilers and interpreters. Some fundaes about how to link code in different files. f) What would your friends tell us about you if we ask them? Standard question for everyone. Company: HCL-HP First Interview:- mostly technical. a) Asked about my B.E. b) My preference of posting. They asked this initially before launching into any other questions. I told them Madras. Remainder of the interview was mostly on OS and C. Nothing on networks. Thus I have this inkling that they frame their questions on the basis of what you specify as your preference of posting and depending on what projects are available there.

c) What architectures, apart from 8085, do you know? --- Nothing very deep and I told them as much. d) Give the contents of process stack for the execution of a particular C-program they give. ------ The C-program as such is not important. You just have to remember the order in which the return address of any function/procedure call, the parameters, and the local variables are stored on the stack. ( I guess, any CO book should have this. Maurice Bach talks about user and kernel stacks) e) What all are shared by parent and child processes immediately after parent executes a fork system call? Cross questioned about the 'copy on write' facility and 'dup' system call. --- again see MB, and also Stevens' 2nd chapter. f) What events happen when the following command is given? cat /etc/passwd | more ---- Describe how the shell forks the two processes and how the pipe gets created between them. Cross question: How does 'cat' know that its output has to be written into the pipe and not into standard o/p? g) Have you written any TSR's? --- No.

What are TSR? ----Terminate but stay resident programs. Then does it mean DOS is a multitasking system? ---- No, TSRs are interrupt driven h) How are Windows programs different from normal C-programs? ---- Windows programs are event driven. What can be the various types of events? --- See Primer/API i) Difference between swapping and paging. ---- Swapping is moving entire processes between main memory and hard disk. Paging is moving individual pages of a process. j) Write a program to list all palindromes in a string. ----- Hint: use a stack and some extra storage for remembering previous palindromes. k) What's the output? char *cp; int *ip; cp=(char *)0x100; ip=(int *)cp; ip++; cp++; printf("cp = %x ip = %x", cp, ip); Ans:cp = 0x101 ip = 0x102 ...(why?) l) What are static variables and functions? There are two files, say, file1 and file2. file1 has a global declaration static int x; file2 has a global declaration int y; What is the difference between the two types of declarations when you link file1 and file2? --- x is local to functions in file1 and cannot be seen by functions in file2. y can be seen by functions in both file1 and file2. m) How does a debugger set breakpoints in a code you are debugging? ---- some funda regarding insertion if an interrupt instruction in the code....don't know for sure. (It seems that this q was also asked by some other company. Worth knowing the answer.) This was followed by a shady psychological test. You are given a set of six pictures. Look at each picture and write a story on each. Second interview: (fully personal) --- This was more interesting;-) a) What did you feel about the ppt? --- wasn't very impressive so gave some shady answer. b) Have you heard of creativity? -- Ya. Have you heard of Bernard Shaw? -- Ya.

bible.

(Then he rattled off some quote of BS regarding creativity) What do you say? --- I put some shadiest fundaes regarding visionaries and Leonardo da Vinci conceptualising Helicopters in his time! ************************************************************************ NOTE: If you have been offered a job previously by any other company after your BTech/BE or if you have even slightest of work experience then make it a point to mention about it. It is a major plus point. The interviewers will be definitely interested in knowing that some other company also found you good enough to be selected. ************************************************************************ Company name: Cadence design systems(I) P Lts, Noida. Year: 1995 Area of work : They develop CAD tools for VLSI design etc. They call it EDA ( Electronic design automation) They expect people with good C knowledge, data structures , compiler knowledge Selection procedure : -----------------1. Written test a. Logic and aptitude test - 20mts. b. software and hardware part -30 mts. Software part - questions on datastres e.g. given inorder exp.and preorder exp. findout the postorder exp., binary tree insertion, stacks - set of operations are given , predict the output.., static variables..

Hardware part basic questions on digital systems such as K-maps, DMA , floating pt. representation, signed integer representation, cache location etc. 2. Interview Technical Questions asked: For me almost Nil. a)question: what 'lex' does ? Personal Questions asked: a)question 1. Tell me about urself, family background .. 2. Btech projects and M.S. projects ( spend more time here, even if u have not done much workl; create a good impression) 3. Significant achievements in life. ( may be paper publications etc. ) 4. Why did u leave ur previous company ( If u were working) 5. What do u expect from a company ? ( like how shd be the work environment etc. etc. ) ************************************************************************

Interviews Attended : Siemens, Motorola, NetQuest Company name: Siemens Year: 1995 Technical Questions asked: 1. Draw the Architecture of Unix ? I asked please elaborate He then told Draw the Unix Architecture ! 2. Suppose there are two processes communicating via TCP ports One of them on one machine dies. What will happeen to the port? If another process is allocated that port will it receive garbage.? 3. What are the various IPC mechanisms? Why is message passing coslier than semaphore? 4. Name a simple scehme to communicate among two processes on a same machine without the pipes, semaphores, shared memory message passing, sockets etc etc hi fi stuffs? Hint : Think Simple 5. What are the tables and their relations when two processes access some files ? Company name: Motorola Year: 1995 Technical Questions asked: 1. Give a general algo for converting a m-ary tree to a 2-ary tree. 2. How many links are there in a binary tree of N nodes? Give a proof? 3. What are skew trees? For a tree with 4 nodes draw all possible binary ? Generalise for n nodes how many binary trees can be drawn? 4. Have u used threaded trees anytime in your life time?

Company name : NetQuest 1. Assume a long linked list. Some nodes instead of pointing to their next node, point backwards. This is called a corrupted node. Give an algo in C to test whether a list is corrupted or not. No extra space in nodes, in efficient time. less memory. marks a function of time and storage used. 2. A macro to test whether a number is a power of 2. 3. There is a two-dimensional linked list. Each node has a, North, South, West, East pointers. Write fragment of C Code to do some interchanging stuffs. North points to West, West point to South et etc, ( A glorified version of reverse of linked list) 4-7. Questions like these, basically pointer stuffs 8 Assume there are two cubes. U can write one digit (0-9) on each of these sides, Write in such a way that when u keep two cubes side by side, u should be able to show all days in a month. (1-31) Company name: INFOSYS Year: 1995 Technical Questions asked: 1. Explain your project 2. What are your areas of interest in Appli Prog Personal Questions asked:

1. 2. 3. 4. 5. 6. 7. 8.

Introduce yourself Why do you want to join INFOSYS Do you have a passport Have you taken GRE/TOEFL Will you go abroad Which prog is better - MTech or MS Which prog do people prefer - MTech or MS Why

1) Name of Company: Wipro InfoTech Technical Questions: Why doesn't fortran support recursion? Dynamic Storage allocation not there (I think) What is the problem with a software like ethernet monitor? No security and privacy for network users. Give page table format and translation of virtual address to physical address? Tanenbaum - os book Device Drivers in general and Streams drivers in particular What is a clone open in Streams? Sun Device Driver Manual (No. 17 I think not sure) CPU scheduling, which is best and why? Which will cause starvation? Tanenbaum - os book Deadlocks? Tanenbaum - os book

Hierarchical resource allocation? Tanenbaum - os book How is a macro different from a function? Who doesn't know! Explain your research work? Summarize what you learnt in each of your course work. 2) Personal Questions: Some - They wouldn't be relevant to others. Name of company: Novell Technical Questions: Device Drivers, Structure of a streams driver. Sun Device Driver Manual (No. 17 I think not sure)

How do you enforce consistency of data structures of the driver in a multiuser environment? Sun Device Driver Manual (No. 17 I think not sure) TCP/IP fundamentals. Internetworking with TCP/IP - Comer ARP/ RARP fundamentals. Internetworking with TCP/IP - Comer How long does a packet of size ... take to travel in an ethernet? Networks - Tanenbaum List all the process calls generated in Unix from the time a process is created till it dies? (GOK - God Only Knows!) Try Maurice Bach - might be there. Tell why fork and exec are implemented as two different calls and not as one? (GOK - God Only Knows!) Try Maurice Bach - might be there. Differentiate Repeater, Bridge, Router, Gateway. What is an adaptive learning bridge? Networks - Tanenbaum Explain your research work? Personal Questions: Hajaar - Wouldn't be relevant.

3) Oracle Technical Questions: Explain your research work. Given a C program, tell me how it would go into the address space of the computer? Which would go where? There were uninitialized and initialized global variables and local variables and two functions? (I don't know) Distributed memory - cache consistency problem, issues and solutions. (Tanenbaum - os) Write a CPU Scheduler implemeting priority scheduling in C language - 20 lines of code, 10 minutes time. Also give the data structure to use. Use a doubly linked list. Quite simple if you don't get tensed up.

Personal Questions: None. Company name:Motorola Year:1995 Technical Questions asked: 1)Describe Thesis work. 2)Are you interested in working in GUI 3)Are you interested in "List of user interface related software". 4)What is the latest in continuous speech recognition? 5)What other methods other than neural networks can be used for recognition of speech? 6)What are the differences between pascal and C? 7)What is strongly typed? 8)What other differences...... Personal Questions asked: a)Which other companies are you applying to? Company name:TISL Year:1995 Technical Questions asked: 1)About project 2)What will you do three years from now? 3)Which other companies have you applied to? Company name: Wipro infotech Year: 1995 Technical Questions asked: a)question DMA operation, cycle stealing, scope rules in C recursive function for fibonacci series generation, complexity for searching in binary trees. b)answer (if you know it)

Personal Questions asked: a)question b)your response Company name: Cadence designs Year: 1995 Technical Questions asked: Written test consisting of 1. Aptitude test, 2. C programming and data structures, 3. Digital electronics Personal Questions asked: in interview a)question my weakness, kinds of friendship, family details b) response

They are impressed if one presents papers. I have presented conference papers in the national level. Generally most of the companies asks about the project. Regarding other technical questions, they put questions on the courses I did. Personal ----------i) Tell us something about yourself. (This has to be there) ii) Strengths and weaknesses (This question also disguised in various forms is always asked). iii) Why should we hire you? iv) Can you describe your project in short? v) Why did you take 2-1/2 years to complete (My case!) vi) If given the job when can you join. (Caution: Don't think that if you give some unreal early deadlines they will offer you the job. Always play safe and give a deadline by which time you are sure to complete and join. Asking for extensions is the worst scenario). Tips: Be confident, frank (But need not give away information which may weigh against your case), free (use first names while addresing them, so be alert when they introduce themselves) and cheerful (attend an interview with a positive frame of mind). Remember you are IITians and you always have an edge. That may sound arrogant, but its true. --------------------------------------------------------------1.non verbal question: four figures are given, find 5th figure. ans: 1st figure.

2.draw the venn diagram for flowers, clothes & white ans: -------------| | -----------------------| | | | | | | | | | | | |flower | | | |clothes | -----------------------| white | -------------3.there are 6 boys--a,b,c,d,e,f and 5 girls -- p,q,r,s,t. a team should be formed with 6 members--and some more conditions like c and d should sit together; p won't sit with e. there are 4 q's based on this ref:puzzle test of agarwal 4.a cube is painted with blue, yellow and black on opposite faces.it is cut into 36 cubes,of which 4 cubes are bigger than others. 3 q's on this.

hint:first cut cube into 3 equal pieces(not cubes).cut first piece into 16 equal cubes(4x4).cut 3rd piece into 16 equal cubes(4x4).cut the 2nd piece (middle piece) into 4 equal cubes(bigger in size than previous 32 cubes). 5.a sales executive has to visit 6 companies--p,q,r,s,t,u.other conditions like --he should visit s before u ,he should not visit r immediately after u etc.., ref:puzzle test of agarwal 5.4 members--2 men ,2 women are palying cards.no woman should sit in front of another woman.no man should sit in front of another man. man1 sits on west side etc..,find the position of woman2. 6.a container contains 28 litres of pure milk. then 8 litres of milk is taken out and 8 litres of water is added.then another 8 litres of mixture is taken out and another 8 litres of water is added. this process is repeated 3rd time also.find the milk-water ratio. section 2:(c-programming) 1.debugging is done finding a)logical errors b)run time errors c)both a and b d)none of the above ans:c 2.sum(x)=1+ 1+2+ 1+2+3+ .....x write the condition'?' { for(i=0;i<?;i++) for(j=0;j<?;j++) sum+=z } 3.show that a variable is the largest among the 3 variables using conditional operator a=5,b=10,c=7 ans:(a>b)?((a>c)?a:c):b b is the largest there are 3,4 q's on syntax/logical/runtime errors. and 2,3 q's on for loops. -------------------------------------------------------------------------> Analytical: > ------------> > 1. Given a cube, with different colors on its faces, and then is cut > into 64 pieces, and the questions relate to the colors of different > colored small cubes. > > 2. A few ladies and gents sit around table in some given order and 4 > questions are about their seating arrangement with some restrictions. > > 3. Draw a venn diagram for 3 items : white, flowers, cloth > > Ans : draw 3 circles each intersecting the other , with white kept in the > middle. > > 4. A problem related to seating arrangement of 4 people ( 2 ladies and

> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >

2 gents) with some restrictions 5. problem related to milk with water added to it for three times Ans: 20.5 litres 6. Problem related to diagrams . Five diagrams were given and asked to find the sixth one. C-Skills: -------1. Max number of nodes in a binary tree with height 3 is 20 : Ans: False 2. 10,20,30,40,50,60 : give the order when put in a queue and in a stack Ans : Queue : 10,20,30,40,50,60 stack : 60,50,40,30,20,10 3. Debugging is the process of finding Ans : logical and runtime errors 4. trace the error: void main(){ int &a; /* some other stuff here */ } Ans: syntax error 5. a problem with a function named 'myValue' will be given and asked to find the value of main() for an argument of 150, Ans : 150 6. Some problems related to 'for' loops. 7. problem on conditional inclusion.

> 8. problem related to depth first and breadth first search (DSA subject) > > 9. study the syntax of malloc function > > 10. locate the error > > int arr (20); > Ans: syntax error. > 1. Matricide:Mother::Homicide:? a)Human b)Children c)Father d)None 2.Rs.3 costs 5 oranges.Then sold each orange at 1 rupee each.Then sold each orange at 1 rupee each.For Rs.36 profit what is the no. of oranges required?

Ans.90 3 The wages of the worker was increased from Rs.18 to Rs.21 per week.The average working hours is 7 hrs/day instead of 8 hrs/day.How much fast wokers should do work? 4.A sales person visits M,N,P,Q,R and S S can be varied according to the question. Ans. S MNPQR

5. A cube is colored on the opposite faces blue,black and yellow.It is then cut into 36 cubes.Out of which 32 were small cubes and 4 where big cubes. a)How many cubes were there,colored on the face b)How many cubes were colored on three faces. 6. A cask contain 40 liters milk.8 liters we taken out and filled with water.The same process is contained second&third time.How much amount of milk will be there? 'c language ---------int a[100]; int i; x= 0 y= 100 ------------------for(i=1;i<=4;i++) } return;

1).

main() {

TECHNICAL TEST 1. 2. 3. 4. One Nibble = ? Hexadecimal and Octal representation of 1024 ? What a compiler does ? DOS ? (whether Graphical interface or Character interface and two more choices are given) 5. CPU - abbrevation 6. Fortran used as ( Ans : Scientific Language) 7. ASCII character set ? (total number) 8. Windows NT- What NT stands for? 9. Which is not an input device ? (keyboard, Disk, Mouse,Lightpen) 10. Which is not a pointing device ?( mouse,Joy stick,lightpen none)

11. 12. 13. 14. 15.

Microsoft Chief ? 4GL ? (Fortran,SQL,ADA, ....) Father of Computers? Which of them is Object Oriented Language.? Power PC is the product of ? (Microsoft,IBM,Apple,Motorola,Intel) (A combination of any correct 3 companies) 16. Latest processor used ? (Pentium, Power PC, Pentium pro,none) 17. MS Word is ? 18. First Super Computer built in India. (Ans : param) 19. Which of the following companies donot manufacture chips? (Microsoft, Motorola, Intel, HP) 20. LAN - abbrevation 21. WAN - abbrevation 22. Modem is ? (related to electrical hardware.- Like Modulator &demodulator) 23. FDD - abbrevation ( floppy disk drive) 24. BIT - abbrevation 25. Information is ? (message, data,processed data,none) 26. Which is not networking ?(internet,ethernet,arcnet,none) 27. One Gigabyte =?( 2 power30 , 2 power 20 ,2 power 10 none) 28. Which of the following is not RDBMS ? (sybase, SQL,Acess,none)_ 29. Oracle is ? (Ans : Relationasl Data Base Management System) 30. In Oracle, Table means ( Ans : Collection of records) 31. DMA - abbrevation (Direct Memory Access,Discrete memory Access, Disk memoryaccess) 32. What is meant byStatic Variable ? 33. What is meant by QUEUE? {refer any data structures text} 34. What is meant by STACK? {refer any data structures text} 35. The processor used in first IBM PC? (8086,8088,zig4,intel) 36. Difference between 80286 and 80287 37. In bubble sort , no. of comparisons required ?(ans : formula : N*(N-1)/2) 38. No. of comparisons of an item in 100 items by binary comparison? ( 10,25,50 100) 39. CRT - (Cathode Ray Tube) 40. No. of entryvalues are there in ideally in a subroutine. 41. Binary tree? 42. Flow in one direction ? (Single linked list,Double linked list,.......,....) 43. Electron screen size ? (here, 2 lines of algorithm is given. Name the algoirithm)

44. Which is not storage device.? (printer,CD ROM,Disk,none) 45. A question regarding memory ? ( least used memory,recently unused memory,..) 46. ISO - (International Standard Organisation) 47. HTML - (Hyper Text Makeup Language) 48. Flow chart for factorial N? (ans :choice a) 49. What is meant by Recursion ? 50. Struct(s) { int a; long b; } Union (u)

{int a; long b; } Print sizeof(s)and sizeof(u) if sizeof(int)=4 and sizeof(long)=4 51.Switch (i) i=1; case 1 i++; case 2 ++i; break; ( ans : 1,2,3,none) case 3 --i; Output of i after executing the program 52. char S; char S[6]= " HELLO"; printf("%s ",S[6]); output of the above program ? 53. Unsigned char c; for ( c=0;c!=256;c++2) printf("%d",c); No. of times the loop is executed ? (127,128,256,infinitely) 54. int i; i=0; repeat i=i+1; <====== PASCAL PROGRAM print i; until(i<10) end No. of times the loop is executed? (0, ASCII 0, I,unpredictable)

55.

convert (int A,var ,int B;int c) { A=10; B=4-; C=120; } Convert (inta,b,c) { <====== PASCAL PROGRAM a=1; b=4; c=12; } convert (A,B,c) ? (10,40,120

10,40,12,..........,............) 56. Procedure A Begin -------end Procedure B Begin ----------end 57. int i; i=2; i++; if(i=4) { printf(i=4); } else { printf(i=3); } output of the program ? <====== PASCAL PROGRAM No. Of errors in the program ?(1,2,3,none)

(4,3,unpredictable,none)

58. what is FAT?. File allocation table QUANTITATIVE APPTITUDE TEST : --------------------------Total 44 questions are there. Refer R.S. Aggarwal 1. 2. 3. 4. How many degrees hours hand rotate in 10 minutes? 1/(10 power 18) - 1/(10 power 20) = ? 0 <x < 1: Which is greater ? (1/(x square),1/x,x,x square) c=a/b ; a-1=c What is the relation between a&b############

5.

N = ((8.42)**2)*(95. ....)/((0.982)*(64.....)**2) If N contains the first three digits as 988,Which of the following is the nearest answer (9.88,98.8,988,none) 6. The sum of 7 consecutive odd integers with 27 as the fourth number. 7. (66666666666666)**2 + 888888888888=? 8. 2486724...... Express it in product of 3 numbers.(The given number is not exactly correct. Choices are given. Very easy) 9. Radius of sphere is increased by 50%. By how much percentage is surface area is increased. 10. In which of the following , 2 as a common factor , can be eliminated.

Ans

log(x square)/log(y square)

log(x)/log(y)

Antonyms : 11. AUSPICISIOUS 12. REHALISHLY 13. & 14. Sentence correction 15, 16 , 17 Spelling Mistakes 18, 19 Two Questions 6 letters are assigned certain numbers. In each qusetion , 4 combination of digits are given . Of which , which gives a meaningful word. 20 & 21. - 4 sentences will be given in each question. Arrange them in logical order . 22. 5 straight lines are cut in a circle. A question regarding this. Reasoning : a) b) c) d) If statement A alone is required If statement B alone is required If bothe statements A & B are required Neither

23. Does Mr. Mathew give tution ? A) MAthew is a teacher B) In school, the teacher is not expected to give tutions. 24. There is no power cut in advanced country If T is a city, Is there power cut in that city? A) Z is a advanced country B) T ia a capital city of country Z 25. Tanzanians are in East Africa. Tanzanizns are good in either Education , Dance or Music A) Tanzanians are good at Education B) East Africa are good at dance & Music. Remaining questions 26 - 29 are of the same type.

30. On onw day, 14 children are admitted in a school by their mothers. 2 are sisters, 3 are brothers,2 are brother and sister and 2 are twins. The rest are singles. How many mothers came? (5 , 7, 9, 14)

31. Problem Cisterns & pipes. It will take 8hrs to fill a cistern. But due to leak at the bottom, it take 10 hrs to full it. In how many hrs, th eful tank will be emptied because of leak.? (18,8,40,10) 32. Question regarding men & work A does alone a work in 4 days B does alone a work in 8 days C does alone a work in 10 days A & B together ------

C & B together -----33. In 3.5 Kg rod , there is 74% silver. If it is alloyed with a 0.5 Kg rod, the % of silver goes p to 84%. The percent of silver in 0.5 Kg rod? 34. Two chords of lengths 2L1 and 2L2 are drawn in a circle. Their lengths are inversely proportional to the straight distance joining the centre. Find the radius of circle. 35. A every 36 - 40 A question on transportation table. 5 questions were given. ------------------------------------------------------A B C D E ------------------------------------------------------A X 12 8 20 6 ------------------------------------------------------B 12 X 12 5 9 ------------------------------------------------------C 20 8 X 4 7 ------------------------------------------------------D 3 15 6 X 10 ------------------------------------------------------E 12 5 8 3 X ------------------------------------------------------A,B,C,D,E denote the stages. X denote the start of the stage. The bus goes from A to E and E to A woith back stops at B,C, & D For each the charge is Rs.0.70 The numbers in the table are how many passengers are there in the bus upto that stage.( the numbers given the table are not correct) 36. Total no. of passengers in onward journey 37. Total amount in the conductors bag just before the bus reaches the stage C Kg of tea costs Rs 49.50 . But the supplier gives 10 gms less for Kg he sold. What is the actual cost.

38.

How many Rs. 1.40

tickets are issued to passengers in backward journey.

39. If the bus breaks down between the stages C & D , the amount refunded to passengers. 40. If the ticket costs Rs.1.50, how much is the profit in Backward journey. PART 1

1). A beggr collects cigarette stubs and makes one ful cigarette with every 7 stubs. Once he gets 49 stubs . How many cigarettes can he smoke totally. Ans. 8 2). A soldiar looses his way in a thick jungle at random walks from his camp but mathematically in an interestingg fashion. First he walks one mile east then half mile to north. Then 1/4 mile to west, then 1/8 mile to south and so on making a loop. Finally hoe far he is from his camp and in which direction. ans: in north and south directions 1/2 - 1/8 + 1/32 - 1/128 + 1/512 - and so on = 1/2/((1-(-1/4)) similarly in east and west directions 1- 1/4 + 1/16 - 1/64 + 1/256 and so on = 1/(( 1- ( - 1/4)) add both the answers 3). hoe 1000000000 can be written as a neither of them containing zeros Ans 2 power 9 x 5 ppower 9 product of two factors

( check the answer )

4). Conversation between two mathematcians: first : I have three childern. Thew pproduct of their ages is 36 . If you sum their ages . it is exactly same as my neighbour's door number on my left. The sacond mathematiciaan verfies the door number and says that the not sufficient . Then the first says " o.k one more clue is that my youngest is the youngest" Immmediately the second mathematician answers . Can you aanswer the questoion asked by the first mathematician? What are the childeren ages? ans 2 and 3 and 6 How many times did it

5). Light glows for every 13 seconds . between 1:57:58 and 3:20:47 am ans : 383 + 1 = 384

6). 500 men are arranged in an array of 10 rows and 50 columns . ALL tallest among each row aare asked to fall out . And the shortest among THEM is A. Similarly after resuming that to their originaal podsitions that the shorteest among each column are asked to fall out. And the longest among them is B . Now who is taller among A and B ? ans A

7). A person spending out 1/3 for cloths , 1/5 of the remsaining for food and 1/4 of the remaining for travelles is left with

Rs 100/- . How he had in the begining ? ans RS 250/-

8). there are six boxes containing 5 , 7 , 14 , 16 , 18 , 29 balls of either red or blue in colour. Some boxes contain only red balls and others contain only blue . One sales man sold one box out of them and then he says " I have the same number of red balls left out as that of blue ". Which box is the one he solds out ? Ans : total no of balls = 89 and (89-29 /2 = 60/2 = 30 and also 14 + 16 = 5 + 7 + 18 = 30 9). A chain is broken into three pieces of equal lenths conttaining 3 links each. It is taken to a backsmith to join into a single continuous one . How many links are to tobe opened to make it ? Ans : 2. 10). Grass in lawn grows equally thickand in a uniform rate. It takes 24 days for 70 cows and 60 for 30 cows . How many cows can eat away the same in 96 days.? Ans : 18 or 19 11). There is a certain four digit number whose fourth digit twise the first digit. Third digit is three more than second digit. Sum of the first and fourth digits twise the third number. What was that number ? Ans : 2034 and 4368 Part 2. 1. From a evaporates. evaporates. the II day. vessel on the first day, 1/3rd of the liquid On the second day 3/4th of the remaining liquid what fraction of the volume is present at the end of is

2. an orange galss has orange juice. and white glass has apple juice. Bothe equal volume 50ml of the orange juice is taken and poured into the apple juice. 50ml from the white glass is poured into the orange glass. Of the two quantities, the amount of apple juice in the orange glass and the amount of orange juice in the white glass, which one is greater and by how much? 3. there is a 4 inch cube painted on all sides. this is cut into no of 1 inch cubes. what is the no of cubes which have no pointed sides.

4. sam and mala have a conversation. sam says i am vertainly not over 40. mala says i am 38 and you are atleast 5 years older than me. Now sam says you are atleast 39. all the sattements by the two are false. How hold are they realy. 5. ram singh goes to his office in the city, every day from his suburbun house. his driver mangaram drops him at the railway station in the morning and picks him up in the evening. Every evening ram singh reaches the station at 5 o'clock. mangaram also reaches at the same time. one day ramsingh started early from his office and came to the station at 4 o'clock. not wanting to wait for the car he starts walking home. Mangaram starts at normal time, picks him up on the way and takes him back house, half an hour early. how much time did ram singh walk. 6. in a railway station, there are tow trains going. One in the harbour line and one in the main line, each having a frequency of 10 minutes. the main line service starts at 5 o'clock. the harbour line starts at 5.02a.m. a man goes to the station every day to catch the first train. what is the probability of man catchinhg the first train 7. some people went for vaction. unfortunately it rained for 13 days when they were there. but whenever it rained in the morning, they had clean afternood and vice versa. In all they enjoyed 11 morning and 12 afternoons. how many days did they stay there totally 8. exalator problem repeat 9. a survey was taken among 100 people to firn their preference of watching t.v. programmes. there are 3 channels. given no of people who watch at least channel 1 " " 2 " " 3 no channels at all atleast channels 1and 3 " " 1 and 2 " " 2 and 3 find the no of people who watched all three.

10. albert and fernandes they have two leg swimming race. both start from opposite and of the pool. On the first leg, the boys pass each other at 18 mt from the deep end of the pool. during the II leg they pass at 10 mt from the shallow end of the pool. Both go at const speed. but one of them is faster. each boy rests for 4 sec to see at the end of the i leg. what is the

length of the pool. 11. T I S I S -------------X F X X X X U X -------------X X N X X -------------H Each alphabet stands for one digit, what is the maximum value T can take

1. an escalator is descending at constant speed. A walks down and takes 50 steps to reach the bottom. B runs down and takes 90 steps in the same time as A takes 10 steps. how many steps are visible when the escalator is not operating. 2. evvery day a cyclist meets a train at a particular crossing. the road is straignt before the crossing and both are travelling in the same direction. cyclist travels with a speed of 10 Kmph. One day the cyclist comes late by 25 min. and meets the train 5km before the crossing. what is the seppd of the train. 3. five persons muckerjee, misra, iyer, patil and sharma, all take then first or middle names in the full names. There are 4 persons having I or middle name of kumar, 3 persons with mohan, 2 persons withdev and 1 anil. --Either mukherjee and patil have a I or middle name of dev or misra and iyer have their I or middle name of dev --of mukherkjee and misre, either both of them have a first or middle name of mohan or neither have a first or middle name of mohan --either iyer of sharma has a I or middle name of kumar hut not both. who has the I or middle name of anil 4. a bird keeper has got Ppigeon, M mynas and S sparrows. the keeper goes for lunch leaving his assistant to watch the birds. a. suppose p=10, m=5, s=8 when the bird keeper comes back, the assistant informs the x birds have escaped. the bird keeper exclaims oh no! all my sparrows are gone. how many birds flew away. b. when the bird keeper come back, the assistand told him that x birds have escaped. the keeper realised that atleast2 sparrows have escaped. what is minimum no of birds that can escape.

5.

select from the five alternatives A,B,C,D,E AT THE end of each question ,two conditions will be given. the choices are to filled at follows. a. if a definete conclusion can be drawn from condition 1 b. if a definete conclusion can be drawn from condition 2 c. if a definete conclusion can be drawn from condition 1 and 2

d. if a definete conclusion can be drawn from condition 1 or 2 e. no conclusion can be drawn using both conditions 1. person 1 says N<5 person says n>5 person 3 says 3N>20 person 4 says 3n>10 person 5 says N<8 whaT IS value of N a) 1. no of persons who speak false being less than no of persons who tells the truth. 2. person 2 is telling the truth. b) 1. no of persong telling the truth is greater than no of persons telling lies 2. person 5 is telling the truth. 6. there are N coins on a table. there are two players A&B. you can take 1 or 2 coins at a time. the person who takes the last coin is the loser. a always starts first --1. if N=7 a) A can always win by taking two coins in his first chanse b) B can win only if A takes two coins in his first chance. c) B can always win by proper play d) none of the above --2. A can win by proper play if N is equal to a) 13 b) 37 c) 22 d) 34 e) 48 ans. e. --3. B can win by proper play if N is equal to a) 25 b)26 c) 32 d) 41 e) none --4. if N<4, can A win by proper play always 7. Two turns have vertain pecular charcteristics. One of them always lies on Monday, Wednesday, Friday. \the other always lies on Tuesdays, thursdays and saturdays. On the other days they tel the truth. You are given a conversation. person A-- today is sunday my name is anil person B-- today is tuesday, my name is bill 8. There were 36 chairs. how many ways can they be placed such that all rows have equal no. of chairs and atleast three chairs are there in each row and there are atleast three rows. 5 ways. 9. There are 27 balls, of which 1 is heavier. given a balance how many times you need to weigh to find out the odd ball. 3 Weighs. 10. Product of three consecutive nos. 210. of two least numbers 11. What is the sum

11.

If the area of the sqaure is increased by 69 % how much the length of the side will increase? 30%

12.

if the sum of five consecutive nos. 35? how many prime nos are there : 2 primes.

13.

if the length of the rectangle is reduced by 20% and breath is increased by 20 % what is the net change ? 4 % decrease 14. A question on sets. There are some 20 Basketball players & 30 Football players, and 25 cricket players. 1 of them plays all the three games. 8 of them plays atleast two games. They are 50 altogether. How many of them plays none of the games. 15. A question on directions. B is 20 miles east of A. D is 30 miles east of C. E is 10 miles north of D. C is 20 miles north of B. How far E is from A? Some 3 questions on Reasoning like, 16. If you say that giving stock options to employees increases the productivity of the company, which of the following sentences support it. A) Giving stock options increases the morale of the employees .. .. etc., 17. Gamblers comes to the Amusement parks. There are some Amusement parks in each city. There are some gamblers in each city. So what can you infer. A) Amusement park always have gamblers. .. .. etc., Technical Questions. 1. Whether all recusive pgm can be writtten iteratively? yes. 2. What data structes you will use if you want to go to first record from the last and vice versa? doubly linked circular list 3. Given 10000 nos. and 48MB Memory. What is the complexity of the efficient sorting algo.? (the algo. is not mentioned) O(N) 4. Given a C code and ask what it does? code was something similar to Bubble sort and that particular code does the sorting in Desending order and the complexity is O(n^2)(which is the next question).

5.

A code like this is given. a. for(i=0;i<num;i++) b. for(i=num;i>0;i--) Assuming no code optimization and assume that the microprocessor has flags etc. which one is correct. b will execute faster.

6. If there are too many page faults what is the problem? 7. To ensure one pgm. doesnt corrupt other pgm. in a Multi-pgm enviornment what you should do? 8. Which one you will use to implement critical section? Binary Semaphore 9. Which one is not needed for Multi-processing. enviornment? options are: virtual memory,security,time sharing,none of the above. 10. Which one is not done by Data link layer ? bit stuffing, LRC,CRC,parity check 11. Which one is not related to Data link layer? 12. Which one is not suitable for client-server application? tcp/ip,message passing,rpc,none of the above. 13. What is SQL. Procedural Relational DB Query Language. 14. Indexing in databases give you options were like 1.efficient deleting and inserting 2.efficient deleting. etc. 15. int a=1,b=2,c=3; printf("%d,%d",a,b,c); What is the output? 16. Scope of Static Variable ............ in a file. 17. for(i=0; i<=10;i++,printf("%d",i)); +18. Real Time Os should have a)fast context switch b)Virtual memory etc. 19. Messages are transferred in some E71 code, where after 7 bits of data, 1 bit of stopping data is to be transferred. what should be done. options were like a) send directly b) send after encoding etc. (+- is there in the questions)

20. There are three processes A, B, C. A sends data header stores it and sends the data to C. C returns message, identifies the message and adds the header sends to A.B receives the messages from C such that B are pending. Identify the best Data Structure. section 2: oracle:

to B. B removes the it to B. B receives the that was stored and atmost 'm' messages

1. what is sparese matrices?. give (at least) two methods for implemetation rather than two dimentional array. 2.what are cheap locks/latches?. 3.what is two phase locking?. Name two locks. 4. What are volatile variables in C?. What is their significance ?. 5. will these two work in same manner #define intp int * typedef int * inpp; 6. what are binary trees?. what is its use?. section 3 : 1. What is polymorphism? 2. What is Inheritence?. 3. Mention four Object Oriented Programming Languages?> 4. Mention basic concepts of OOP. 5. What are messages in OOP?. 6. What is garbase collection?. 7.what is object?. 8. what is a class?. section 4: 1. expand the following: a.SEI b. ISO 2. what are different levels of SEI?. 3. What is significance of ISO?> 4. Expand the following: a. WWW b. HTTP c. HTML d. TCP/IP 5. what is Black box testing?. 6. explain the following: 1. white box testing 2. white box testing 3. boundary testing 4 stress 5. negative 6. system 7. unit 8.module 9.destructive

-------------------------------------------------------------------------paper -----1)which of following operator can't be overloaded. a)== b)++ c)?! d)<= 2)#include<iostream.h> main() { printf("Hello World"); } the program prints Hello World without changing main() the o/p should be intialisation Hello World Desruct the changes should be a)iostream operator<<(iostream os, char*s) os<<'intialisation'<<(Hello World)<<Destruct b) c) d)none of the above 3)CDPATH shell variable is in(c-shell) a) b) c) d) 4) term stickily bit is related to a)kernel b)undeletable file c) d)none 5)semaphore variable is different from ordinary variable by 6)swap(int x,y) { int temp; temp=x; x=y; y=temp; } main() { int x=2;y=3; swap(x,y); } after calling swap ,what are yhe values x&y? 7) static variable will be visible in a)fn. in which they are defined b)module " " " " c)all the program d)none 8)unix system is a)multi processing b)multi processing ,multiuser c)multi processing ,multiuser,multitasking d)multiuser,multitasking 9)x.25 protocol encapsulates the follwing layers a)network b)datalink c)physical d)all of the above e)none of the above

10)TCP/IP can work on a)ethernet b)tokenring c)a&b d)none 11)a node has the ip address 138.50.10.7 and 138.50.10.9.But it is transmitting data from node1 to node2only. The reason may be a)a node cannot have more than one address b)class A should have second octet different c)classB " " " " " d)a,b,c 12)for an application which exceeds 64k the memory model should be a)medium b)huge c)large d)none 13)wrong statement about c++ a)code removably b)encapsulation of data and code c)program easy maintenance d)program runs faster 14)struct base {int a,b; base(); int virtual function1(); } struct derv1:base{ int b,c,d; derv1() int virtual function1(); } struct derv2 : base {int a,e; } base::base() { a=2;b=3; } derv1::derv1(){ b=5; c=10;d=11;} base::function1() {return(100); } derv1::function1() { return(200); } main() base ba; derv1 d1,d2; printf("%d %d",d1.a,d1.b) o/p is a)a=2;b=3;

b)a=3; b=2; c)a=5; b=10; d)none

15) for the above program answer the following q's main() base da; derv1 d1; derv2 d2; printf("%d %d %d",da.function1(),d1.function1(),d2.function1()); o/p is a)100,200,200; b)200,100,200; c)200,200,100; d)none 16)struct { int x; int y; }abc; you can not access x by the following 1)abc-->x; 2)abc[0]-->x; abc.x; (abc)-->x; a)1,2,3 b)2&3 c)1&2 d)1,3,4 17) automatic variables are destroyed after fn. ends because a)stored in swap b)stored in stack and poped out after fn. returns c)stored in data area d)stored in disk 18)which is right in ms-windows a)application has single qvalue system has multiple qvalue b) " multiple " " single " c)" " " multiple " d)none 18)variable DESTDIR in make program is accessed as a)$(DESTDIR) b)${DESTDIR} c)DESTDIR d)DESTDIR 19)the keystroke mouse entrie are interpreted in ms windows as a)interrupt b)message c)event d)none of the above 20)link between program and out side world (ms -win) a)device driver and hardware disk b)application and device driver c)application and hardware device d)none 21)process dies out but still waita a)exit

b)wakeup c)zombie d)steep

22)in dynamic memory allocation we use a)doubly linked list b)circularly linked c)B trees d)L trees e)none 23)to find the key of search the data structure is a)hask key b)trees c)linked lists d)records 24)which is true a)bridge connects dissimiler LANand protocol insensitive b)router " " " " " c)gateway " " " " " d)none of the above section 3:: 1.Max value of SIGNED int 2.One questin is given, long one, to find the answer U should be femiliar with the operation as follows int *num={10,1,5,22,90}; main() { int *p,*q; int i; p=num; q=num+2; i=*p++; print the value of i, and q-p, and some other operations are there. } how the values will change?? 3. One pointer diff is given like this: int *(*p[10])(char *, char*) asked to find the meaning. 4. char *a[4]={"jaya","mahe","chandra","buchi"}; what is the value of sizeof(a)/sizeof(char *) a. 4 b.bytes for char c-- d.-( we don't know the answer) 5. void fn(int *a, int *b) { int *t; t=a; a=b; b=t; } main() {

int a=2, b=3; fn(&a,&b); print the values os a and b; } what is the output--- out put won't swap, the same values remain. a. error at runtime b. compilation error c.2 3 d. 3 2

6. #define scanf "%s is a string" main() { printf(scanf,scanf); } what is the output. ANS : %s is string is string 7. i=2+3,4>3,1; printf("%d"i); ans is 5 only. 8. char *p="abc"; char *q="abc123"; while(*p=*q) { print("%c %c",*p,*q); } a. aabbcc b. aabbcc123 c. abcabc123 d. infinate loop ( this may be correct) 9. printf("%u",-1) what is the value? a. -1 b. 1 c. 65336 d. -(maxint value-1 I think, check for the answer)

10. #define void int int i=300; void main(void) { int i=200; { int i=100; print the value of i; } print the value of i } what is the output? may be 100 200

11. int x=2; x=x<<2; printf("%d ",x); ANS=8;

12. int a[]={0,0X4,4,9}; int i=2; printf("%d %d",a[i],i[a]); what is the value??? (may be error) /*some values are given*/

-----------------------------------------------------------------------1.const char * char * const What is the differnce between the above two?. 2.In Unix inter process communication take place using?. 3.What are the files in /etc directory?. 4.About i-node numbers 5.Max relaxable permisssion value with out giving write permission to others?. 6.About ln(linking) 7.A question on until until (who |grep mary) do sleep(60) done 8.Linking across directories?. 9.process id for kernell process 10.very first process created by kernell 11.function to repaint a window immediately?. 12.Function entry for DLL in win3.1 13.win 3.1 is a 14.win 3.1 supports which type of multi tasking?. 15.Message displayed when a window is destroyed 16.About fork()? 17.About send message and post message 18.Message to limit the size of window 19.System call executable binary file intoa process 20.About GDI object?. 21.API used to hide window 22.Initialize contents of a dialog?. _____________________________________________________________________ section: electronics:

1.4 stage ripple counter with delay(f/f) 10msec. How much time it takes for a state to change. 4*10=40. 2.impedence of a p'lel resonant circiut at resonance:R. 3.serial to parellel conversion is done by ans:shift register. 4.if the address bus id 20bits.then the memory space is 1Mb. 5.filtering can be done with:capacitor,iductor,both,none. 6.the config that is worst effected by low CMMR ans:Non inverting amplifier. 7.two progs are given. one satrts counting frm 0 to MAX and the other stars frm MAX to 0. which one executes fast.may be Max to 0.Think of.it should be.

Networks: 1.the fctn of datalink layer is:bit stuffing. 2.which of the following is not fctn of datalink layer: Encription. 3.voltage levels of rs232x:+12,-12. 4.which of the following is not used for client/server. RPC,TCP/IP,MESSAGEQs None ans:may be none. compiler/algo/ds: 1.Data structure used to impliment a menu: doubly linked circular linked list. 2. some regular expression is given:WaW'.may be it is context free grammar. os: 1.the feature of real time os is: fast context swithing. 2.os impliments protection with the help of hardware(like virtual addressing in 386/286 etc).

1) A - G are 7 consecutive +ve integers not necessarily in the same order 1) B is the middle number 2) D is 3 less than c 3) the difference between F & A is equal in magnitude and sign to the difference between E & C 4) Neither F nor C lie between E & G a) What is the value of B-F 1 2 -1 -2 cannot be determined

b) which is greatest F C A E cannot be determined

c) Given both A & B are primes what is the lowest value of E 8 6 9 12 cannot

2) Given that a,b,c,d,e each represent one of the digits between

1-9 and that the following multiplication holds a b c d e 4 ---------e d c b a What digit does e represent a) b) c) d) e) 4 6 7 8 none

1. How many butes does an array A(1:8,-2:2,1:5) require for storage if each element of the array is 24 bits long. 200 2. begin i:=0; j:=0; | block d loop: if(i != 0) i := i-1; else i := i+1; i := i+1; j := j+1; | block a | block b 480 600 800 none

if (j <= 25) goto loop; end | block c of i at [c] the goto executed the loop executed if i is initialized to 1 the loop entered if the block [b] is changed

a) What is the value 2 ? b) How many times is 25 ? c) How many times is in [d] 26 d) How many times is to j=j+1 ?

e) What is the value of i at [c] interchanging blocks [a] and [b] ? 2 ? Follow the instructions given below [ From 1 to 8 ]

1. A cause B or C but not both 2. F occurs only if B occurs 3. D occurs if B or C occurs 4. E occurs if only c occurs 5. J occurs only if E or F occurs 6. H occurs if E occurs 7. D causes G, H or Both. 8. G occurs if F occurs. Questions --------1. If A occurs which of the following may occur 1. F & G Ans -- (a) 1 only (e) 1,2 & 3 2. If B occurs which must occur Ans --(a) F & G (b) D & G (c) D (d) G & H (e) J (ii) E & H (iii) D

(b) 2 only (c) 3 only (d) 1,2,3 or 2 & 3 but not 1

3. If J occurs which must occur Ans (a) E (b) Both E & F (c) Either B or C (d) B (e) Both B & c 4. Which may occur as a result by a cause not mentioned. (I) D (II) A (III) F Ans --(a) I only (b) II (c) I & II (d) II & III (e) I,II,III 5. If E occurs which cannot occur. (a) F (b) A (c) D (d) C (e) J #include<stdio.h> int SumElement(int *,int); void main(void) { int x[10]; int i=10; for(;i;)

} int SumElement(int array[],int size) { int i=0; float sum=0; for(;i<size;i++) sum+=array[i]; return sum; }

} printf("%d",SumElement(x,10));

i--; *(x+i)=i;

#include<stdio.h> void main(void); int printf(const char*,...); void main(void) { int i=100,j=10,k=20; int sum; float ave; char myformat[]="ave=%.2f"; sum=i+j+k; ave=sum/3.0; printf(myformat,ave); } #include<stdio.h> void main(void); void main(void) { int a[10]; printf("%d",((a+9) + (a+1))); } #include<stdio.h> void main(void); void main(void) { struct s{ int x; float y; }s1={25,45.00}; union u{ int x; float y; } u1; u1=(union u)s1;

printf("%d and %f",u1.x,u1.y);

#include<stdio.h> void main(void) { unsigned int c; unsigned x=0x3; scanf("%u",&c); switch(c&x) { case 3: printf("Hello!\t"); case 2: printf("Welcome\t"); case 1: printf("To All\t"); default:printf("\n"); } }

#include<stdio.h> int fn(void); void print(int,int(*)()); int i=10; void main(void) { int i=20; print(i,fn); } void print(int i,int (*fn1)()) { printf("%d\n",(*fn1)()); } int fn(void) { return(i-=5); } #include<stdio.h> void main(void); void main(void) { char numbers[5][6]={"Zero","One","Two","Three","Four"}; printf("%s is %c",&numbers[4][0],numbers[0][0]); } int bags[5]={20,5,20,3,20}; void main(void) { int pos=5,*next(); *next()=pos; printf("%d %d %d",pos,*next(),bags[0]); } int *next() { int i;

for(i=0;i<5;i++) if (bags[i]==20) return(bags+i); printf("Error!"); exit(0);

#include<stdio.h> void main(void) { int y,z; int x=y=z=10; int f=x; float ans=0.0; f *=x*y; ans=x/3.0+y/3; printf("%d %.2f",f,ans); }

#include<stdio.h> void main(void); double dbl=20.4530,d=4.5710,dblvar3; void main(void) { double dbln(void); dblvar3=dbln(); printf("%.2f\t%.2f\t%.2f\n",dbl,d,dblvar3); } double dbln(void) { double dblvar3; dbl=dblvar3=4.5; } return(dbl+d+dblvar3);

#include<stdio.h> static int i=5; void main(void) { int sum=0; do { sum+=(1/i); }while(0<i--); } #include<stdio.h> void main(void) {

int oldvar=25,newvar=-25; int swap(int,int); swap(oldvar,newvar); printf("Numbers are %d\t%d",newvar,oldvar); } int swap(int oldval,int newval) { int tempval=oldval; oldval=newval; newval=tempval; } #include<stdio.h> void main(void); void main(void) { int i=100,j=20; i++=j; i*=j; printf("%d\t%d\n",i,j); }

#include<stdio.h> void main(void); int newval(int); void main(void) { int ia[]={12,24,45,0},i,sum=0; for(i=0;ia[i];i++) { sum+=newval(ia[i]); } printf("Sum= %d",sum); } int newval(int x) { static int div=1; return(x/div++); } #include<stdio.h> void main(void); void main(void) { int var1,var2,var3,minmax; var1=5; var2=5; var3=6; minmax=(var1>var2)?(var1>var3)?var1:var3:(var2>var3)?var2:var3; printf("%d\n",minmax); } #include<stdio.h> void main(void);

void main(void) { void pa(int *a,int n); int arr[5]={5,4,3,2,1}; pa(arr,5); } void pa(int *a,int n) { int i; for(i=0;i<n;i++) printf("%d\n",*(a++)+i); } #include<stdio.h> void main(void); void print(void); void main(void) { print(); } void f1(void) { printf("\nf1():"); }

#include "6.c" void print(void) { extern void f1(void); f1(); } static void f1(void) { printf("\n static f1()."); } #include<stdio.h> void main(void); static int i=50; int print(int i); void main(void) { static int i=100; while(print(i)) { printf("%d\n",i);i--; } } int print(int x) { static int i=2; return(i--); } #include<stdio.h>

void main(void); typedef struct NType { int i; char c; long x; } NewType; void main(void) { NewType *c; c=(NewType *)malloc(sizeof(NewType)); c->i=100; c->c='C'; (*c).x=100L; printf("(%d,%c,%4Ld)",c->i,c->c,c->x); } #include<stdio.h> void main(void); const int k=100; void main(void) { int a[100],sum=0; for(k=0;k<100;k++) *(a+k)=k; sum+=a[--k]; printf("%d",sum); } This question paper is C&COBOL TEST PAPER. ----------------------------------------------------1) Which of these is an invalid dataname? a) wd-count b) wd_count c) w4count d) wdcountabcd 2) What is the output of the following program main () { unsigned int i; for (i = 10; i >= 0; i--) printf ("%d", i); } a) prints numbers 10 - 0 b) prints nos 10 - 1 c) d) goes into infinite loop 11) What is the value of the following expression? i = 1; i << 1 % 2 a) 2 b) c) 1 d) 0 12) What is the value of the following expression? i = 1; i = (i <<= 1 % 2)

a) 2 c) 0

b) d) erroneous syntax

What is the result? 13) *A + 1 - *A + 3 a) b) -2 c) 4 d) none of the above 14) &A[5] - &A[1]? a) b) c) 4 d) 15) C allows a) only call by value b) only call by reference c) both d) only call by value and sometimes call by reference 16) The following statement is " The size of a struct is always equal to the sum of the sizes of its members" a) valid b) invalid c) can't say 17) How many x's are printed? for (i = 0, j = 10; i < j; i++, j--) printf ("x"); a) 10 b) 5 c) 4 d) none

18) output? main () { int i = 2, j = 3, k = 1; swap (i, j) printf ("%d %d", i, j); } swap (int i, int j) { int temp; temp = i; i = j; j = temp; } YOU KNOW THE ANSWER 19) main () { int i = 2; twice (2); printf ("%d", i); } twice (int i) { bullshit } int i, b[] = {1, 2, 3, 4, 5}, *p;

p = b; ++*p; p += 2; 20) What is the value of *p; a) 2 b) 3 c) 4 d) 5 21) What is the value of (p - (&p - 2))? a) b) 2 c) d) 23) x = fopen (b, c) what is b? a) pointer to a character array which contains the filename b) filename whithin double quotes c) can be anyone of the above d) none 24) x = malloc (y). Which of the following statements is correct. a) x is the size of the memory allocated b) y points to the memory allocated c) x points to the memory allocated d) none of the above 25) which is the valid declaration? a) #typedef struct { int i;}in; b) typedef struct in {int i;}; c) #typedef struct int {int i;}; d) typedef struct {int i;} in;

26) union { int no; char ch; } u; What is the output? u.ch = '2'; u.no = 0; printf ("%d", u.ch); a) 2 b) 0 c) null character 27) Which of these are valid declarations? i) union { int i; int j; }; iii) union { int i; int j; FILE k; }; ii) union u_tag int i; int j;

d) none

};

iv) union { int i; int j; }u;

a) all correct c) ii & iv

b) i, ii, iv d)

28) p and q are pointers to the same type of dataitems. Which of these are valid? i) *(p+q) ii) *(p-q) iii) *p - *q a) all b) c) iii is valid sometimes 29) which are valid? i) pointers can be added ii) pointers can be subtracted iii) integers can be added to pointers a) all correct b) only i and ii 30) int *i; float *f; char *c; which are the valid castings? i) (int *) &c ii) (float *) &c iii) (char *) &i 31) int i = 20; printf ("%x", i); what is the output? a) x14 b) 14 c) 20 d) none of the above

32) main () { char *name = "name"; change (name); printf ("%s", name); } change (char *name) { char *nm = "newname"; name = nm; } what is the output? a) name b) newname c) name = nm not valid d) function call invalid 33) char name[] = {'n', 'a', 'm', 'e'} printf ("name = \n%s", name); a) name = name b) name = followed by funk characters c) name = \nname

d) none 34) int a = 0, b = 2; if (a = 0) b = 0; else b *= 10; what is the value of b? a) 0 b) 20 c) 2 d) none 35) int x = 2, y = 2, z = 1; what is the value of x afterh the following statmements? if (x = y%2) z = crap else crap a) 0 b) 2 c)1 d)none 37) output? initially n = -24; printd (int n) { if (n < 0) { printf ("-"); n = -n; } if (n % 10) printf ("%d", n); else printf ("%d", n/10); printf ("%d", n); } a. -24 b.24 c.-2424

38) float x, y, z; scanf ("%f %f", &x, &y); if input stream contains "4.2 3 2.3 ..." what will x and y contain after scanf? a. 4.2, 3.0 b. 4.2, 2.3 39) #define max(a,b) (a>b?b:a) #define squre(x) x*x int i = 2, j = 3, k = 1; printf ("%d %d", max(i,j), squre(k)); output? a.32 b.23 c.31 d.13

40) struct adr { char *name;

char *city; int zip; }; struct adr *adradr; which are valid references? i) adr->name X ii) adradr->name iii) adr.zip X iv) adradr.zip 41) main (x, y) int x, char *y[]; { printf ("%d %s", x, y[1]); } output when invoked as prog arg1 a. 1 prog b. 1 arg1 c. 2 prog d. 2 arg1 42) extern int s; int t; static int u; main () { } which of s, t and u are availeble to a function present in another file a. only s b. s & t c. s, t, u d. none

43) main () { } int a; f1(){} f2(){} which of the functions is int a available for? a. all of them b. only f2 c. only f1 d. f1 and f2 only

int a = 'a', d = 'd'; char b = "b", c = "cr";

main () { mixup (a, b, &c); } mixup (int p1, char *p2, char **p3) { int *temp; ....doesnt matter..... } 44) what is the value of a after mixup? a. a b.b c.c d.none of the above 45) what is the value of b after mixup? a. a b.b c.c d.none of the above 46) main () { char s[] = "T.C.S", *A; print(s); } print (char *p) { while (*p != '\0') { if (*p != ".") printf ("%s", *p); p++; } } output? a.T.C.S b.TCS c. d. none of the above 47) a question on do ... while 48) a question on % operator

49) main () { int ones, twos, threes, others; int c; ones = twos = threes = others = 0; while ((c = getchar ()) != EOF) { switch (c) { case '1': ++ones; case '2': ++twos; case '3': ++threes; break;

default: ++others; break; } } printf ("%d %d", ones, others);

if the input is "1a1b1c" what is the output? a. 13 b. c. 33 d. 31 ************************************************************************** PART II QUANTITATIVE APTITUDE ,TIME 20 Min. MARKS :30. ----------------------------------------------------------------1. Two pencils costs 8 cents, then 5 pencils cost how much (Ans:20 cents). 2. A work is done by the people in 24 min. one of them can do this work a lonely in 40 min. how much time required to do the same work for the second person. (ans:60 min.) 3. A car is filled with four and half gallons of oil for full round trip. fuel is taken 1/4 gallons mor3 in going than coming. what is the fiel consumed in coming up? (2 gallons) 4. low temperature at the night in a city is 1/3 more than 1/2 hinge as higher temperature in a day. sum of the low temp and higherst temp is 100C. then what is the low temperature (40 C) 5. A person who decided to go weekend trip should not exceed 8 hours driving in a day Average speed of forward journy is 40 mph. due to traffic in sundays, the return journey average speed is 30 mph. how far he can select a picnic spot (120 miles). 6. A sales person multiplied a number and get the answer is 3, instead of that number divided by 3. what is th answer he actually has to get ? (1/3). 7. A ship started from port and moving with I mph and another ship started from L and moving with H mph. At which place these two ships meet ? ( Ans is between I and J and close to J) !_____!_____!_____!_____!_____!_____! port G H I J K L 8. A building with hight D ft shadow upto G A neighbour building with what height shadow C ft is (B ft.) !_____!_____!_____!_____!_____!_____!_____! A B C D E F G H 9. A person was fined for exceeding the speed limit by 10 mph.Another person was also fined for exceeding the same speed limit by twice the same. If the second person was travelling at a speed of 35 mph. find the speed limit (15 mph) 10. A bus started from bustand at 8.00a m and after 30 min staying at destination, it returned back to the bustand. the destination is 27 miles

from the bustand. the speed of the bus 50 percent fast it retur4ns to the bustand (11.00)

speed at what time

11.in a mixture, R is 2 parts, S is 1 part. in order to make S to 25% of the mixture, howmuch R is to be added ( one part). 12. wind flows 160 miles in 330 min, for 80 miles how much time required. 13. with 4/5 full tank vehicle travels 12 miles, with 1/3 full tank how much distance travels ( 5 miles). 14. two trees are there. one grows at 3/5 of the other. in 4 years, total growth of trees is 8 ft. what growth will smaller tree will have in 2 years. (<2ft) 15. A storm will move with a velocity of towords the center in hours. At the same rate how much far will it move in hrs. (but Ans is 8/3 or 2 2/3). PART III: TIME 25 Min, MARKS :50. ----------------------------------------------CRITICAL REASONING: THERE WILL BE 13 PASSAGES WITH 50 QUESTIONS TIME 30 MIN. (ANSWERS WILL BE AS YES/NO/CAN'T SAY we are giving our answers, please check.) 1. My father has no brothers. he has three sisters who has two childs each. 1> 2> 3> 4> 5> my grandfather has two sons (f) three of my aunts have two sons(can't say) my father is only child to his father(f) i have six cousins from my mother side(f) i have one uncle(f)

2. Ether injected into gallablader to dissolve galstones. this type oneday treatment is enough for gallstones not for calcium stones. this method is alternative to surgery for millions of people who are suffering from this disease. 1> calcium stones can be cured in oneday (f) 2> hundreds of people contains calcium stones(can't say) 3> surgery is the only treatment to calcium stones(t) 4> Eather will be injected into the gallbleder to cure the cholestrol based gall stones(t).

3. Hacking is illigal entry into other computer. this is done mostly because of lack of knowledge of computer networking with networks one machine can access to another machine. hacking go about without knowing that each network is accredited to use network facility. 1> Hacking people never break the code of the company which they work for (can't say). 2> Hacking is the only vulnerability of the computers for the usage of the data.(f) 3> Hacking is done mostly due to the lack of computer knowledge (f). (there will be some more questions in this one ) 4. alphine tunnels are closed tunnels. in the past 30 yrs not even a single accident has been recorded for there is one accident in the rail road system.

even in case of a fire accident it is possible to shift the passengers into adjacent wagons and even the living fire can be detected and extinguished with in the duration of 30 min. 1> no accident can occur in the closed tunnels (True) 2> fire is allowed to live for 30 min. (False) 3> All the care that travel in the tunnels will be carried by rail shutters.(t) 5. In the past helicopters are forced to ground or crash because of the formation of the ice on the rotors and engines. a new electronic device has been developed which can detect the watercontent in the atmosphere and warns the pilot if the temp.is below freezing temp. about the formation of the ice on the rotors and wings. 1> the electronic device can avoid formation of the ice on the wings (False). 2> There will be the malfunction of rotor & engine because of formation of ice (t) 3> The helicopters are to be crashed or down (t) 4> There is only one device that warn about the formation of ice(t). 6.In the survey conducted in mumbai out of 63 newly married house wives not a single house wife it that the husbands should take equal part in the household work as they felt they loose their power over their husbands. inspite of their careers they opt to do the kitchen work themselves after coming back to home. the wives get half as much leisure time as the husbands get at the week ends. 1> housewives want the husbands to take part equally in the household(f) 2> wives have half as much leisure time as the husbands have(f) 3> 39% of the men will work equally in the house in cleaning and washing 7. copernicus is the intelligent. In the days of copernicus the transport and technology development was less & it took place weeks to comunicate a message at that time.wherein we can send it through satellite with in no time --. even with this fast developments it has become difficult to understand each other. 1> people were not intelligent during Copernicus days (f). 2> Transport facilities are very much improved in noe a days (can'say) 3> Even with the fast developments of the techonology we can't live happily.(can't say) 4> We can understand the people very much with the development of communication(f). Q8) senior managers warned the workers that because of the intfoductors of japanese industry in the car market. There is the threat to the workers. They also said that there will be the reduction in the purchase of the sales of car in public.the interest rates of the car will be increased with the loss in demand. 1> japanese workers are taking over the jobs of indian industry. (false) 2> managers said car interests will go down after seeing the raise in interest rates.(true) 3> japanese investments are ceasing to end in the car industry.(false) 4> people are very much interested to buy the cars.(false) Q9) In the totalitariturican days,the words have very much devalued.In

the present day,they are becoming domestic that is the words will be much more devalued. In that days, the words will be very much effected in political area.but at present,the words came very cheap .we can say they come free at cost. 1> totalitarian society words are devalued.(false) 2> totalitarian will have to come much about words(t) 3> The art totalitatian society the words are used for the political speeches. Q10) There should be copyright for all arts. The reele has came that all the arts has come under one copy right society,they were use the money that come from the arts for the developments . There may be a lot of money will come from the Tagore works. We have to ask the benifiters from Tagore work to help for the development of his works. 1> Tagore works are came under this copy right rule.(f) 2> People are free to go to the because of the copy right rule.(can't say) 3> People gives to theater and collect the money for development. (can't say) 4> We have ask the Tagore resedents to help for the developments of art.(can't say) NOTE : DO 1,2,3,4,5 PASSAGES WHICH ARE EASY. LAST BUT ONE ALSO. DO THAT PASSAGES CAREFULLY. TIME WILL BE INSUFFICIENT. PASSAGES ARE NOT AS EXACTLY AS ABOVE. THERE IS HIGHLEVEL ENGLISH IN ALL THE PASSAGES, WE ARE GIVING IN OUR OWN WORDS , U CANNOT EXPECT THE SAME TYPE OF ENGLISH THERE. WHILE ANSWERING U SHOULD BE VERY FAST, DO NOT WASTE TIME, IT IS INSUFFICIENT,TRY TO ANSWER AS MANY AS POSSIBLE. SECTION 4. PSYCHOMETRIC TEST. ---------------------------------------DO NOT BOTHERE ABOUT MUCH ABOUT THIS TEST. BE OPTIMISTIC WHILE ANSWERE. THERE WILL BE 150 QUESTIONS IN 30 MIN. THE QUESTIONS IN THIS SECTION MAY REPEATED WITH SLIGHT VARIATIONS ANSWER SHOULD BE SAME IN BOTH THE CASES. (ans will be as yes/no/can't say) for example 1> you will be interested in social activities. 2> while going upstairs you will move two steps at a time. 3> you will be making friendship with same sex or with opposite sex also. 4> your friends will consider u as a leader in your group 5> people think that your'e serious minded.

6> some times you feel dull without any reason. 7> your'e host or hostes for several parties. 8> relatives come to your house you will entertain them. 9> you will do work for longtime without tireness. 10> in your company you want lead the organasition. etc.. the qwestions may repeate several times so becareful and give same ans's. SECTION 1 INTURN CONSISTS OF THREE PARTS.

PART 1

VERBAL--IT CONSISTS OF 40 WORDS WHICH HAS 5 MULTIPLE ANSWERS FOR THEM.THE MAIN WORDS WHICH I REMEMBER ARE AS FOLLOWS FOR WHICH YOU SHOULD LEARN THE SYNONYMS OF THESE---

merry= gay alienate= estrange solicit= beechat heap= to pile cargo= freight momentary= transient volume= quantity veer= diverge dispel= dissipate admonish= cautious meager= scanty latitude= scope latent= potential covet= crave discretion= prudence latent= potential emanicipate= liberate lethargy= stupor concur= acquiesce confiscate= appropriate baffle= frustrate subside= wane misery= distress pretentious= ostentatious tranquil= serene efface= obliterate obstinate= stubborn hover= linger caprice= whim belate= too late renounce= reject brim= border divulge= reveal lament= wail bileaf= conviction adhesive= tenacious furtive= stealthy hamper= obstruct to merit= to deserve SECTION 1 PART B 20MIN 30 marks 15 QUANTITATIVE. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ THESE ARE SOME PROBLEMS : 1.) two pencils cost 8 cents. then 5 pencils cost? (20 cents) 2. A work is done by the people in 24 minutes. One of them can do this workalonely in 40 minutes. How much time to do the same work for the second person? (60 minutes)

3. A car is filled with four and half gallons of fuel for a round trip. Fuel is taken 1/4 more in going then coming. What is the fuel consumed in coming up? (2 gallons) 4.Low temperature at the night in a city is 1/3 more than 1/2 high as higher temperature in a day. Sum of the low tem. and highest temp. is 100 degrees. Then what is the low temp? (40 deg.) 5. A person, who decided to go to weekened trip should not exceed 8 hours driving in a day. Average speed of forward journey is 40 m/h. Due to traffic in sundays, the return journey average speed is 30 m/h. How far he can select a picnic spot? a) 120 miles b) between 120 and 140 miles c) 160 miles ans: 120 miles 6. A salesperson multiplied a number and get the answer 3, instead of that number devided by 3. what is the answer he actually has to get? 1 x 3 = 3 so number = 1 devided by 3, the ans. is 1/3. 7. A ship started from port and moving with I miles per hour and another ship started from L and moving with H miles per hour. At which place these two ships meet? |----|----|----|----|----|----| port G H I J K L

8. A building with height D shadow upto G. A neighbour building with what height shadows C feet. |----|----|----|----|----|----|----| A B C D E F G H 9. A person was fined for exceeding the speed limit by 10 mph. Another person was also fined for exceeding the same speed limit by twice the same. If the second person was travelling at a speed of 35 mph, find the speed limit. (15 mph) 10.A bus started from bustand at 8.00am, and after 30 minutes staying at destination, it returned back to the busstand. The destination is 27 miles from the busstand. The speed of the bus is 18mph. In return journey bus travels with 50% fast speed. At what time it returns to the busstand? (11.00am). 11.In a mixture, R is 2 parts, S is 1 part. In aoder to make S to 25% of the mixture, howmuch r is to be added? 12. wind flows 160 miles in 330 min, for 80 miles how much time required. 13. with 4/5 full tank vehicle travels 12 miles, with 1/3 full tank how much distance travels ( 5 miles )

14. two trees are there. one grows at 3/5 of the other in 4 years, total growth of trees is 8 ft. what growth will smaller tree will have in 2 years ( < 2 ft. ) 15. A storm will move with a velocity of towards the centre in At the same rate how much far will it move in hrs. ( but the answer is 8/3 or 2 2/3 ) SECTION-1 PART-3 CRITICAL REASONING marks-50 questions-50 30 min hours,

1. My father has no brothers. he has three sisters who has two childs each My grandfather has sons. a) my grandfather has two sons b) three of my aunts have two sons c) my father is only child to his father d) i have six cousins from jmy mother side e) i have one uncle 2. Ether injected into gallablader to dissolve galstones. this type oneday treatment is enough for gallastones not for calcium stones. this method is alternative to surgery for millions of people who are suffering from this disease. a) calcium stones can be cured in oneday b) hundreds of people contains calcium stones c) surgery is the only treatment to calcium stones 3. Hacking is illegal entry into other computer. this is done mostly because of lack of knowledge of computer networking with networks one machine can access to another machine. hacking go about without knowing that each network is accredited to use network facility. a) Hacking people never break the code of the company which they work for b) Hacking is the only vulnerability of the computers for the usage of the data. c) Hacking is done mostly due to the lack of computer knowledge. (there will be some more questions in this one) 4. Alphine tunnels are closed tunnels. in the past 30 years not even a single accident has been recorded for there is one accident in the rail road system. even in case of a fire accident it is possible to shift the passengers into adjacent wagons and even the living fire can be detected and extinguished with in the duration of 30 min. a) no accident can occur in the closed tunnels b) fire is allowed to live for 30 min. c) all the care that travel in the tunnels will be carried by rail shutters.

5. In the past helicopters are forced to ground or crash because of the formation of the ice on the rotors and engines. a new electronic device has been developed which can detect the watercontent in the atmosphere and warns the pilot if the temp. is below freezing temp. about the formation of the ice on the rotors and wings. a) the electronic device can avoid formation of the ice on the wings

b) there will be the malfunction of rotor & engine because of formation of ice c) the helicopters are to be crashed or down d) there is only one device that warn about the formation of ice. 6. In the survey conducted in mumbai out of 63 newly married house wives not a single house wife felt that the husbands should take equal part in the household work as they felt they loose their power over their husbands. inspite of their careers they opt to do the kitchen work themselves after coming back to home. the wives get half as much leisure time as the husbands get at the week ends. a) housewives want the husbands to take part equally in the household b) wives have half as much leisure time as the husbands have c) 39% of the men will work equally in the house in cleaning and washing 7. In confucius days the technology development was less and it took weeks to communicate a message. wherein we can send it through satellite with in no time........ even with this fast developments it has become difficult to understand each other. a) people were not intelligent during confucius days b) transport facilities are very much improved in now-a-days c) even with the fast developments of the technology we cannot live happily. d) we can understand the people very much with the development of communication. 8. Senior manager in a big company said that new japanies company invades in India for transfering the cars from industrial and warned that jobs were under threat from japanies company. They stated that increasing competence would be coupled with an inevitable down term in car market and recent rise in interest rate which has already hit demand. a) manager issue their warning after a rise in interest rate b) manager told workers that japanies workers are taking jobs away from indian workers c) manager said that more people want to buy new cars in future d) increasing rate of interest mean that japanies firm will create into operate in the country 9. Human existence is suspecious of arbitrary divide between concise and unconcise. The concise world invades shape activity of the unconcise, while many of great activity of humanity waking as whole or partially improved by dreams. Even it could be ignored that dreams precede exceptional such a dichotomy could not be drawn as the influence of dream on waking state would reamin unclear. But as yet no company rebuilt exists to record the substitute of prendtl dreaming. a) sleepy can be creative state b) it is difficult to tell whether a sleeper is dream or not c) if we know what babies would dream about before they are born we could show that the concise and unconcise mind influence on one another d) it is untrue claim that concise and unconcise world never impinge one another 10. Any one who has has systematic exam phases will have perceived a profound although not a prolif of asymmetry whether or not the exception is volitions and self control of spontoneous appeal to predict facial as Symmetry as does the type of emotion potrayed. position can not displace Symmetric at left side regret of a negative emotion is more common posed expression negation emotions are likely to be symmetric representation and where as symmetric occurs relative left sided expression is more common. a) any angry person is more likely to have left sided expression than

some one who has smiling b) an actor is likely to smile symmetric when acting c) delecious facial expression will always be as symmetrical 11. In the totalitariturian days, the words have very much devalued. In the present day, they are becoming domestic that is the words will be much more devalued. In that days, the words will be very much effected in political area. but at present, the words came very cheap, we can say they come free at cost. a) totalitarian society words are devalued b) totalitarian will have to come much about words c) the art totalitarian society the words are used for the political speeches 12. There should be copyright for all arts. the rule has come that all the arts has come under one copy right society, they were use the money that come from the arts for the developments. There may be a lot of money will come from the Tagore works. we have to ask the benifiters from Tagore work to help for the development of his works. a) Tagore works are come under this copy right rule b) people gives to theater and collect the money for development c) people are free to go to the because of the copy right rule d) we have ask the Tagore residents to help for the developments of art. questions ------------------Q9). what will be the result of executing following program main { char *x="new"; char *y="dictonary"; char *t; void swap (char * , char *); swap (x,y); printf("(%s, %s)",x,y); char *t; t=x;x=y;y=t; printf("-(%s, %s)",x,y); } void swap (char *x,char *y) { char *t; y=x;x=y;y=t; } a).(New,Dictionary)-(New,Dictionary) b).(Dictionary,New)-(New,Dictionary) c).(New,Dictionary)-(Dictionary,New) d).(Dictionary,New)-(Dictionary,New) e).None of the above (Ans will be b or e) check Q10).If a directory contains public files (can be valied and used by any one ) which should not be altered ,the most liberal permissions that can be given to the directory is a)755 b)777 c)757

d)775 e)None of the above (Ans a) 11) what would the following program results in main() { char p[]="string"; char t; int i,j; for(i=0,j=strlen(p);i<j;i++) { t=p[i]; p[i]=p[j-i]; p[j-i]=t; } printf("%s",p); } a)will print:string b)will not print anything since p will be pointing to a null string c)will print:gnirtS d)will result in a complication error e)will print invallid characters(junk) (Ans will be b ) check 12) After the following command is executed $ ln old new a listing is performed with the following output $ ls -li total 3 15768 -rw-rw-rw15768 " " 15274 " " 2 you 29 Sep 27 12:07 old " " " " " " new 1 " 40 " " 09:34 veryold

which of the following is true a)old and new have same i-node number,2 b) " " " " " " " , 15768 c)old and new have nothing yo do with each other d)very old and new are linked e)very old and old are linked (Ans is b) 13) What will be the result of executing the following statement int i=10; printf("%d %d %d",i,++i,i++); a).10 11 12 b).12 11 10 c).10 11 11 d).result is OS dependent e).result is compiler dependent (Ans is e)

14) What does extern means in a function declaration a)the funct has global scope b)the funct need not be defined\ c)nothing really d)the funct has local scope only to the file it is defined in

e)none of the above (Ans will be c) 15) What will be result of the following program main() { void f(int,int); int i=10; f(i,i++); } void f(int i,int j) { if(i>50) return; i+=j; f(i,j); printf("%d,",i); } a).85,53,32,21 b)10,11,21,32,53 c)21,32,53,85 d)32,21,11,10 e)none of the above (Ans is e) 16). MS windows 3.1 is a a)operating system b)Application c)Programing language d)database e)shell (Ans will be b) 17).MS Windows 3.1 supports which tyoe of multi-tasking? a)cycle b)executive c)preemptive d)Non-preemptive e)Manual (Ans ) 18)The command ......ln/bin/mail /usr/you/bin/m a)will not be executed because you are linking files across different file systems b)results ln /bin/main being the same file as /usr/you/bin/m c)results in 2 links to the file mail d) " " " " m e)none (Ans will be b)

19) What is the size of 'q'in the following program? union{ int x;

char y; struct { char x; char y; int xy;}p; }q; a)11 b)6 c)4 d)5 e)none (Ans is b why because no of bytes for int =4 given in instructions) 20) Which message is displayed when a window is destroyed a)WM_CLOSE b)WM_DESTROY c)WM_NCDESTROY (Ans is b) 21)Send Message and postmessage are a)send message puts the message in the message queue and results, postmessage processes the message immediately b)Sendmessage processes the message immediately,postmessage puts the message in the queue and returns c) Both put the message in the message queue and returns d) Both process the message immediately e) None of the above (Ans will be b check) 22) Which of the following message is used to limit the size of teh Window a)WM_SIZE b)WM_PAIN (Ans is a)

23)until who|grep mary do sleep 60 done a) is syntactically incorrect b) waits 60 seconds irrespective of Mary being logged in or not c) waits until Marry is logged in d)waits till Mary exited e)None (Ans is c) 24)The UNIX system call that transforms an executable binary file into a process is a)execl() b)execv() c)execle() d)execve() e)All of the above (Ans will be d check)

25)What will be the result of the following program main() { char *x="String"; char y[] = "add"; char *z; z=(char *) malloc(sizeof(x)+sizeof(y)=1); strcpy(z,y); strcat(z,y); printf("%s+%s=%s",y,x,z); } a)Add+string=Add string b)syntax error during compilation c)run time error/core dump d)add+string= e)none (Ans will be e consider cap&small leters) 26)Which of the following is not a DDL object a)HBRUSH b)HPEN c)HBITMAP d)HRGN e)HWND (Ans ic e) 27) Which of the following message is used to initialize the contents of a dialog a)WM_CREATE b)WM_SIZE c)WM_COMMAND d)WM_INITDIALOG e)none (Ans will be d) 28)Interprocess communication in UNIX can be achieved using a)pipe b)Message c)Semaphores d)Shared Memory e)All of the above (Ans is e) 29) Which of the following is true a)UNIX is a time sharing multi-user OS b)UNIX has a device independent file system c)UNIX is full duplex d)UNIX has command interpreter e)All of the above (Ans is e) Q). PS1 pwd export PS1 results in a). your primary prompt being your current directory b). " " and secondary prompts being the current dir c). " " prompt being your home dir d). " " and secondary prompts being the home dir e). None of the above. #################################################

Q).

If you type in the command nohup sort employees > list 2 > error out & and log off ,the next time you log in . the output will be a). in a file called list and the error will de typed in a file error out b). there will be no file called list or error out c). error will be logged in a file called list and o/p will be in error out d). you will not be allowed to log in e). none of the above

Q).enum number { a=-1, b= 4,c,d,e} what is the value of e ? 7,4,5,15,3 (ans is 7 ) check again Q) Result 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 is d ) Q) What is the result main() { char c=-64; int i=-32 unsigned int u =-16; if(c>i){ printf("pass1,"); if(c<u) printf("pass2"); else printf("Fail2");} else printf("Fail1); if(i<u) printf("pass2"); else printf("Fail2") } a)Pass1,Pass2 b)Pass1,Fail2 c)Fail1,Pass2\ d)Fail1,Fail2 e)none

(Ans is c) ################################

APTITUDE TEST ***************************************************** 1) A boy multiplied a number with 10 and got 100,insted of dividing it . If he devided it what would be the answer? (Ans is 1) 2)If 12 shell cup board requires 18ft of wall space then 30 " " " " how much wall space? (Ans is 45) 3)The average salary of three employee is 95Rs.per week. If one employee earns 115 and other earns 65 rupees. how much will third be earn? (Ans is 105Rs) 4)A company instaled 36 punching machines at the begining of the year.In the spring they instaled 9 additional m/c's and then discontinued 18 in the fall.How many were still installed at the end of the year? (Ans is 9)check 5)During a given week a programmer spend 1/4 of his time preparing charts,3/8 of his time for coding,rest of his time for debugging the programs.If he had 48 hrs during the week how many hours did he spend debugging the program. (Ans is 18hrs) 6)A 16 story building has 12000ft on each floor. Company A rents 7 floors and company B rents 4 floors. What is the number of square feet of unrented floor space? (Ans is 60000 sqft) 7)A man owns 2/3 of a computer service buroue business and sells 3/4 of his share for $75000.What is the value of the business. (Ans is 150,000) 8)A computer printer produces 176400 lines in a given day. If the printer was in operation for 7hrs during the day how many lines did it print per minute? (Ans is 420) 9)From its total income a company spent $20000 for advertising half of the remainder on salaries and had $6000 left.What was the total income? (Ans is $32000) 10)In a certain company 20% of the men and 40% of the women attended the annual company picnic.If 35% of all the employees are men .What % of all the employee went to the picnic? (Ans is 33%) 11)The dimensions of certain IBM m/c are 48"*30". If the size of the m/c is increased proportionally until the sum of its dimensions equals to 156".What will be the increase in the shortest side? (Ans is 30) 12)If a card punch operator can process 80 cards in half an hour How many cards can this process in 7hr30min? (Ans is 1200) 13)In a computer tape library there are two racks with 40 tapes per rack.In a given day 30 tapes are in use . What fraction

remains in the rack? (Ans is 5/8)

Anda mungkin juga menyukai