Provided by www.YuvaJobs.com - CDAC Whole Testpaper CDAC Test in APR 2004114.  In the closing days of the civil War, President Abraham Lincoln was  planning to graciously welcome the defeated confederate states back into the Union. After Lincoln was assassinated, however, the "Radical Republicans" in Congress imposed martial law in the South, creating resentment that caused problems well into this century. Had Lincoln lived, the history of regional conflict in 20th century America would have been considerably different.  All of the following assumptions underline the argument above EXCEPT The imposition of martial law in the South was primarily responsible for the resentment felt in the South Had he lived, lincoln would have treated hte defeated South as he had  planned Lincoln would have been able to prevent the Radical Republicans in Congress  from imposing martial law in the South Factors other than the imposition of martial law in the South affected the  history of regional conflicts in 20th century America115 A politician wrote the following: "I realize there are shortcomings to the questionaire method. However, since I send a copy of the quetionnaire to every home in the district, I believe the results are quite representative.... I think the numbers received are so large that it is quite accurate even though the survey is not done scientifically" Most people who received the questionnaire have replied Most people in the district live in homes. the questionnaire method of data collection is unscientific A large, absolute number of replies is synonymous with accuracy116 A worldwide ban on the production of certain ozone-destroying chemicals  would provide only an illusion of protection. Quantities of such chemicals, already produced, exist as coolants in millions of refrigerators. When they reach the ozone layer in the atmosphere, their action cannot be halted. So there is no way to prevent these chemicals from damaging the ozone layer further.  Which of the following, if true, most seriously weakens the argument above?It is impossible to measure with accuracy the quantity of ozone-destroying chemicals that exist as coolants in refrigerators.In modern societies, refrigeration of food is necessary to prevent unhealthy and potentially life-threatening conditions.Even if people should give up the use of refrigerators, the coolants already  in existing refrigerators are a threat to atmospheric ozone.The coolants in refrigerators can be fully recovered at the end of the  useful life of the refrigerators and reused.117 Every town with a pool hall has its share of unsavory characters. This is because the pool hall attracts gamblers and all gamblers are unsavory. Which of the following, if true cannot be inferred from the above? All gamblers are unsavory.All pool halls attract gamblers. Every town has unsavory characters. All gamblers are attracted by pool halls.Directions:- The workweek in a small business is a five-day workweek running from Monday through Friday. In each workweek, activities L,M,N,O and P must all be done.The work is subject to the following restrictions:L must be done earlier in the week than O and earlier than PM must be done earlier in the week than N and earlier than ONo more than one of the activities can ever be done on any one day118 Which of the following is an acceptable schedule starting from Monday to Friday?L, M, N, O, P <-------------ansM, N, O, N, MO, N, L, P, MP, O, L, M, L119 In a game, exactly six inverted cups stand side by side in a straight line, and each has exactly one ball hidden under it. The cups are numbered consecutively 1 through 6. Each of the balls is painted a single solid color. The colors of the balls are green, magenta, orange, purple, red, and yellow. The balls have been hidden under the cups in a manner that conforms to the following conditions:The purple ball must be hidden under a lower-numbered cup than the orange ball.The red ball must be hidden under a cup immediately adjacent to the cup under which the magenta ball is hidden.The green ball must be hidden under cup 5.Which of the following could be the colors of the balls under the cups, in order from 1 through 6?Green, yellow, magenta, red, purple, orangeMagenta, green, purple, red, orange, yellowMagenta, red, purple, yellow, green, orange <-------------ansOrange, yellow, red, magenta, green, purpleDirections:- In a group there are five students coded as P Q R S T.Q and R are intelligent in mathematics and geology. P and R are intelligent in mathematics and hindi. Q and S are intelligent in psychology and buddhist studies.T is intelligent in buddhist studies hindi and psychology120 who is intelligent in psychology, geology and buddhist studiesQ <-------------ansTRSDirections:- The following questions are based on the following situations. Asha, Babli, Charn, Deepti, Eira, Farha are cousins. No two cousins are of the same age , but all have birth days on the same date in that year .The youngest is 17 years old and the oldest is Eira is 22.Farha is somewhere between Babli and Deepti in age.Asha is older than Babli. Charn is older than Deepti121 If asha is one year older than charn the number of logically possible orderins of all six cousins by increasing age is2 <-------------ans( Babli,Asha, Farha, Charn, Deepti, Eira)345122 It is easier to swim in the sea water than in river water becausesea is vast mass of watersea water is generally calmthe density of sea water is higher than river water <-------------ans they water of sea is cool and greenish123 starting from a point x jayant walked 15metres towards the west he turned to his left and walked 20 metres he then turned to his left and walked 15 metres he then further turned to his right and walked 12 metres how far is jayant from the point x and in which direction? N32 metres south -47 metres east W-------E42 metres north -27 metres south <-------------ans S124 Rock and roll music started in the 1950s as a young mans medium and rock is still best performed by men in their twenties and thirties. As rock performers grow into their forties and even fifties, they are simply less physically capable of producing the kind of exciting music they did when they were younger. All of the following assumptions underline the argument above EXCEPT:As rock performers mature, their performances tend to become less excitingRock music is dominated by male performersWomen performers have always played a significant role in rock musicThe physical demands of performing rock are better met by the young <-------------ansMathematical Problems125 Which of the following statements are true, ifx + y + z = 10 y >= 5 and 4 >= z >= 31. x < z2. x > y3. x + z <= y1 only2 only3 only1 and 3 only <-------------ans126 The solution of the equation 4 - 5(2y + 4) = 4 is-2/584-2 <-------------ans127 When x5 + 1 is divided by (x - 2), the remainder is15173133128 How many terms of the series -9 , -6 , -3 ,.........must be taken such that the sum may be 66?11 139 <-------------ans10129 The side of a rectangle are whole numbers. What must their lengths be for the perimeter for the rectangle to be numerically equal to its area?3 and 64 and 54 and 65 and 5 130 A path 7 metres wide surrounds a circular lawn whose diameter is 252m. What is the area of path?5698 sq.mtrs.5000 sq.mtrs.5500 sq. mtrs.None of these131 If the negative of the sum of two consecutive odd numbers is less than -35, which of the following may be one of the numbers?18 <-------------ans161513132 What is the perimeter of a rectangle that is twice as long as it is wide and has the same area as a circle of diameter 8?8(P)1/28P12(2P)1/212P133 Towns A and C are connected by a straight highway which is 60 miles long. The straight line distance between town A and town B is 50 miles, and the straight line distance from town B to town C is 50 miles. How many miles is it from town B to the point on the highway connecting town A and C which is closest to town B?30405060134 A batsman played 17 innings during a season and he was not out. The score of 85 improves his average by 3 runs in the 17th innings. His average score after 16th innings is37353436135 If paper costs 1 paisa per sheet, and a buyer gets a 2% discount on all the paper he buys after the first 1000 sheets, how much will it costs to buy 5000 sheets of paper?Rs 49.30Rs 50.00Rs 39.20Rs 49.20136 The income of a broker remains unchanged though the rate of commission is increased from 4% to 5%. The percentage of slump in business is8%1%20%80%137 There are 4 quarts in a gallon. A gallon of motor oil sells for Rs.12 and a quart of the same oil sells for Rs.5. The owner of a rental agency has 6 machines and each machine needs 5 quarts of oil. What is the minimum amount of money she must spend to purchase enough oil ?Rs.84Rs.94Rs.96Rs.102138 A truck departed from Newton at 11:53a.m. and arrived in Far City, 240 miles away, at 4:41 p.m. on the same day. What was the approximate average speed of the truck on this trip?16/1,200 MPH40/288 MPH1,494/240 MPH50 MPH139 A girl rode her bicycle from home to school, a distance of 15 miles, at an average speed of 15 miles per hour. She returned home from school by walking at an average speed of 5 miles per hour. What was her average speed for the round trip if she took the same route in both directions?7.5 miles per hour10 miles per hour12.5 miles per hour13 miles per hour140 A is thrice as good a workman as B. If the time taken by B to do piece of works exceeds that taken by A by 8 days. In how many days A does the work.841210141 The population of a town was 54,000 in the last census. It has increased 2/3 since then. Its present population is18,00036,00072,00090,000142 One hundred job applicants show up in response to a classified ad. If 60 percent of them are female and if 3/4 of the female applicants are willing to relocate if the job demands it, how many are not willing to relocate?554515It cannot be determined from the information given143 Mr. Smith drove at an average speed of 50mph for the first two hours of his trip. For the next three hours, he averaged 20 mph. What was Mr. Smith`s average speed for the five-hour trip ?20 mph32 mph35 mph38 mph144 A postal truck leaves its station and heads for Chicago, averaging 40mph. An error in the mailing schedule is spotted and 24 minutes after the truck leaves, a car is sent to overtake the truck. If the car averages 50mph, how long will it take to catch the postal truck?1.6 hours3 hours2 hours1.5 hours145 The length breadth and height of a cuboid are in the ratio 1 : 2 : 3. The length, breadth and height of the cuboid are increased by 100%, 200% and 200% respectively. Then the increase in the volume of the cuboid is5 times6 times12 times17 times146 An Automobile covers the distance between two cities at a speed of 60km. per hour and on the return journey it covers at a speed of 40 km. per hour. Find the average speed.60504855147 A man buys 200 shares (par value of Rs.10) of a company, which pays 12% per annum as dividend, at such a price he gets 15% on his money. Find the market value(app.) of a share.Rs. 9Rs. 12Rs. 8Rs. 7.50148 An old picture has dimensions 33 inches by 24 inches. What one length must be cut from each dimension so that the ratio of the shorter side to the longer side is 2:3?2 inches6 inches9 inches10 1/2 inches149 Hiralal earned a profit of Rs. 300 by selling 100 kg of mixture of A and B types of rice at a total price of Rs. 1100. What was the proportion of A and B types of rice in the mixture if the cost prices of A and B types of rice are Rs. 10 and Rs. 5 per kg respectively ?3 : 22 : 52 : 7735 : 2150 A fraction has a value of 2/5. If the numerator is decreased by 2 and the denominator increased by 1, then the resulting fraction is 1/4. What is the value of the numerator of the original fraction ?5678English Language AbilityDirections:- The given pair of words contains a specific relationship to each other. Select the best pair of choices which expresses the same relationship as the given.103 IGNOMINY : DISLOYALTY ::fame : heroismdeath : victoryderelict : foolmartyr : man104 EXPLOSION : DEBRIS ::flood : waterfamine : foodfire : ashesdisease : germ105 Bland : Piquant ::inane : relevantcharlatan : genuineslavish : servileterse : serious106 NEGLIGENT : REQUIREMENT ::remiss : dutycogent :argumenteasy : hardcareful : positionDirections:- Choose the best word, which is most opposite in the meaning to the given word.107 FETTER :delaystretchcomplythrive108 SEDULOUS :rampantesotericmoroseindolent109 SUCCULENT :ordinarytastelessinexpensiveinvigorating110 DORMANT :authoritativeelasticactiveuninteresting111 COURT :rejectuncoverinfectsubjectDirections:- The given pair of words contains a specific relationship to each other. Select the best pair of choices which expresses the same relationship as the given.112 INTIMIDATE : FEAR ::Maintain : satisfactionAstonish : wonderSoothe : concernLion : tameDirections:- Pick out the best choice which can complete the incomplete stem correctly and meaningfully113 It was an extremely pleasant surprise for the hutment-dweller when the Government officials told him that__________he had to vacate hutment which he had been unauthorized occupyinghe had been gifted with a furnished apartment in a multistoried buildinghe would be arrested for wrongly encroaching on the pavement outside his dwellingthey would not accede to his requestOO Programming Concepts88 The ability to reuse objects already defined, perhaps for a different purpose, with modification appropriate to the new purpose, is referred to asInformation hiding.Inheritance.Redefinition.Overloading89 The term given to the process of hiding all the details of an object that do not contribute to its essential characteristics is called _____________.data-hidingpackagingencapsulationabstraction90 Object-oriented technology`s ______ feature means that a small change in user requirements should not require large changes to be made to the system.AbstractionModularityEncapsulationModelling91 An object has _____.StateBehaviourIdentity.All of these options.92 Which of the following is true:Class is an object of an object.Class is meta class.Class cannot have zero instances.None of these options.93 If a derived class object is explicitly destroyed by applying the delete operator to a base-class pointer to the object, the _____ function is automatically called on the objectDerived-class destructor.Base-class destructor.Base-class constructor.Derived-class constructor.94 In object orientated programming a class of objects can _____________ properties from another class of objectsutilizeborrowinheritadapt95 Contracts are not meant to be used in cases of _______.Composition.`has-a` relationship.`is-a` relationship.Both Composition and `has-a` relationship.96 Inheritance through interface is called ________Implementation inheritance.Definition inheritance.Delegation inheritance.Interface inheritance model.97 When a class uses dynamic memory, what member functions should be provided by the class?An overloaded assignment operator.The copy constructor.A destructor.All of these optionsq98 ______ means that both the data and the methods which may access it are defined together in the same unit.Data hiding.EncapsulationData BindingNone of these options99 The term given to the process of hiding all the details of an object that do not contribute to its essential characteristics is called _____________.data-hiding.packaging.encapsulation.grouping100 Car contains a steering wheel is example of ________CompositionAssociationComposition and AssociationNone of these options101 Can two classes contain member functions with the same name?No.Yes, but only if the two classes have the same name.Yes, but only if the main program does not declare both kinds.Yes, this is always allowed.102 A contract is implemented through.ClassInterface.Abstract Class.Interface and Abstract ClassProgramming in C38 The Real constants in C can be expressed in which of the following formsFractional form onlyExponential form onlyASCII form onlyBoth Fractional and Exponential forms<------ans39 The program, which translates high-level program into its equivalent machine language program, is calledTransformerLanguage processorConverterNone of these options<------ans40 Consider the following statements.i.Multiplication associates left to rightii.Division associates left to rightiii.Unary Minus associates right to leftiv.subtraction associates left to rightAll are true<------ansonly i and ii are trueall are falseonly iii and iv are true41 What will be the value of variable a in the following code?unsigned char a;a = 0xFF + 1;printf("%d", a);0xFF 0x1000 <------ans 0x042 What is the output of the following program ?#include <stdio.h>void main(){printf("\n10!=9 : %5d",10!=9);}1 <------ans 0ErrorNone of these options43 #include<stdio.h>void main(){int x=10;(x<0)?(int a =100):(int a =1000);printf(" %d",a);}Error <------ans 1000100None of these options44 Which of the following shows the correct hierarchy of arithmetic operations in C(), **, * or /, + or -(), **, *, /, +, -(), **, /, *, +, -(), / or *, - or + <------ans 45 What is the output of the following code?#include<stdio.h>void main(){int a=14;a += 7;a -= 5;a *= 7;printf("\n%d",a);}112 <------ans 9889None of these options46 What is the output of the following code?#include<stdio.h>#define T tvoid main(){char T = `T`;printf("\n%c\t%c\n",T, t); } ErrorT tT T <------ans.I did,nt get d correct anst t47 The statement that prints out the character set from A-Z, isfor( a = `z`; a < `a`; a = a - 1)printf("%c", &a);for( a = `a`; a <= `z`; a = a + 1)printf("%c", &a);for( a = `A`; a <= `Z`; a = a + 1) <-----ans printf("%c", a);for( a = `Z`; a <= `A`; a = a + 1)printf("%c", a);48 The statement which prints out the values 1 to 10 on separate lines, isfor( count = 1; count <= 10; count = count + 1) printf("%d\n", count);for( count = 1; count < 10; count = count + 1) printf("%d\n", count);<------ansfor( count = 0; count <= 9; count = count + 1) printf("%d ", count); for( count = 1; count <> 10; count = count + 1) printf("%d\n", count);49 What does the term `call-by-reference` refer to?Passing a copy of a variable into a function.Passing a pointer to a variable into a function. <------ansChoosing a random value for a variable.A function that does not return any values.50 What is the output of the following code?#include<stdio.h>void swap(int&, int&);void main(){int a = 10,b=20;swap (a++,b++);printf("\n%d\t%d\t",a, b);}void swap(int& x, int& y){x+=2;y+=3;}14, 2411, 21 <------ans 10, 20Error51 What is the output of the following program code#include<stdio.h>void abc(int a[]){a++;a[1]=612;}main(){char a[5];abc(a);printf("%d",a[4]);}100612Error <------ans None of these options52 which of the following is true about recursive functioni. it is also called circular definitionii. it occurs when a function calls another function more than onceiii. it occurs when a statement within the function calls the function itselfiv. a recursive function cannot have a return statement within it"i and iii<------ansi and iiii and ivi, iii and iv53 What will happen if you assign a value to an element of an array whose subscript exceeds the size of the array?The element will be set to 0Nothing, its done all the timeOther data may be overwrittenError message from the compiler54 What is the output of the following code?#include<stdio.h>void main(){int arr[2][3][2]={{{2,4},{7,8},{3,4},}, {{2,2},{2,3},{3,4}, }};printf("\n%d",**(*arr+1)+2+7);}16 <------ans711Error55 If int s[5] is a one dimensional array of integers, which of the following refers to the third element in the array?*( s + 2 ) <------ans*( s + 3 )s + 3s + 257 #include"stdio.h"main(){int *p1,i=25;void *p2;p1=&i;p2=&i;p1=p2;p2=p1;printf("%d",i);}The output of the above code is :Program will not compile <------ans25Garbage valueAddress of I58 What is the output of the following code ?void main(){int i = 100, j = 200;const int *p=&i;p = &j;printf("%d",*p);}100200 <------ans300None of the above59 void main(){int i=3;int *j=&i;clrscr();printf("%d%d",++*j,*(&i));}What is the output of this program?3 34 3 <------ans4,address of i printedError:Lvalue required60 What is the output of the following code?#include<stdio.h>void main(){int arr[] = {10,20,30,40,50};int *ptr = arr;printf("\n %d\t%d\t",*ptr++,*ptr);}10 2010 10 <------ans20 2020 1061 Which of these are reasons for using pointers?1.To manipulate parts of an array2.To refer to keywords such as for and if3.To return more than one value from a function4.To refer to particular programs more conveniently1 & 3 <------ansOnly 1Only 3All of the above62 struct num{int no;char name[25];};void main(){struct num n1[]={{25,"rose"},{20,"gulmohar"},{8,"geranium"},{11,"dahalia"}};printf("%d%d" ,n1[2].no,(*&n1+2)->no+1);}What is the output of this program?8 88 9 <------ans 9 88 , unpredictable63 During initializing a unionOnly one member can be initialised.All the members will be initialised.Initialisation of a union is not possible.<------ansNone of these options64 Self referential structure is onea. Consisting the structure in the parent structureb. Consisting the pointer of the structure in the parent structureOnly aOnly bBoth a and bNeither a nor b65 Individual structure member can be initialized in the structure itselfTrueFalseCompiler dependentNone of these options66 Which of the following is the feature of stack?All operations are at one endIt cannot reuse its memoryAll elements are of different data typesAny element can be accessed from it directly<------ans<------ans67 When stacks are createdAre initially empty<------ansAre initialized to zeroAre considered fullNone of these options68 What is time required to insert an element in a stack with linked implementation?O(1)O(log2n)<------ans<------ansO(n)O(n log2n)69 Which of the following is the feature of stack?All operations are at one endIt cannot reuse its memoryAll elements are of different data typesAny element can be accessed from it directly<------ans70 Time taken for addition of element in queue isO(1)O(n)O(log n)<------ansNone of these options71 When is linear queue said to be empty ?Front==rearFront=rear-1Front=rear+1Front=rear<------ans72 When queues are createdAre initially empty<------ansAre initialized to zeroAre considered fullNone of the above73 What would be the output of the following program?#include <stdio.h>main(){printf("\n%c", "abcdefgh"[4]);}abcdefghde <------anserror74 Select the correct C code which will read a line of characters (terminated by a \n) from input_file into a character array called buffer. NULL terminate the buffer upon reading a \n.int ch, loop = 0; ch = fgetc( input_file ); while( (ch != `\n`) && (ch != EOF) ) { buffer[loop] = ch; loop++; ch = fgetc( input_file ); } buffer[loop] = NULL;int ch, loop = 0; ch = fgetc( input_file ); while( (ch = "\n") && (ch = EOF) ) { buffer[loop] = ch; loop--; ch = fgetc( input_file ); } buffer[loop] = NULL;int ch, loop = 0; ch = fgetc( input_file ); while( (ch <> "\n") && (ch != EOF) ) { buffer[loop] = ch; loop++; ch = fgetc( input_file ); } buffer[loop] = -1;None of the above75 What is the output of the following code ?void main(){int a=0;int b=0;++a == 0 || ++b == 11;printf("\n%d,%d",a,b);}0, 11, 1 <------ans 0, 01, 076 What is the output of the following program?#define str(x)#x#define Xstr(x)str(x)#define oper multiplyvoid main(){char *opername=Xstr(oper);printf("%s",opername);}opernameXstrmultiply <------ans Xstr77 What is the output of the following code ?#include<stdio.h>#include<string.h>void main(){char *a = "C-DAC\0\0ACTS\0\n"; printf("%s\n",a);}C-DAC ACTSACTSC-DAC <------ans None of these78 #include<stdio.h>void main(){while (1){if (printf("%d",printf("%d")))break;elsecontinue;}}The output isCompile time errorGoes into an infinite loopGarbage values <------ans None of these options79 Select the correct C statements which tests to see if input_file has opened the data file successfully. If not, print an error message and exit the program.if( input_file == NULL ) { printf("Unable to open file.\n"); exit(1); }if( input_file != NULL ) { printf("Unable to open file.\n"); exit(1); }while( input_file = NULL ) { printf("Unable to open file.\n"); exit(1); }None of these options80 The codeint i = 7;printf("%d\n", i++ * i++);prints 49prints 56 <------ans is compiler dependentexpression i++ * i++ is undefined81 Recursive procedure are implemented byLinear listQueueTreeStack<------ans82 Which of these are reasons for using pointers?1. To manipulate parts of an array2. To refer to keywords such as for and if3. To return more than one value from a function4. To refer to particular programs more conveniently1 & 3<------ansonly 1only 3None of these options83 The expression x = 4 + 2 % -8 evaluates to-664None of these options84 What is the output of the following code?#include<stdio.h>main(){register int a=2;printf("\nAddress of a = %d,", &a);printf("\tValue of a = %d",a);}Address of a, 2 <------ans Linker errorCompile time errorNone of these options85 What is the output of the following code?#include<stdio.h>void main(){int arr[]={0,1,2,3,4,5,6};int i,*ptr;for(ptr=arr+4,i =0; i<=4; i++)printf("\n%d",ptr[-i]); (as the 0=4,for -1 it becomes =3)}Error6 5 4 3 20 garbage garbage garbage garbage4 3 2 1 0 <------ans 86 Which of the following is the correct way of declaring a float pointer:float ptr;float *ptr; <------ans*float ptr;None of the above87 If the following program (newprog) is run from the command line as: newprog 1 2 3What would be the output of the following?void main (int argc, char*argv[]){int I,j=0;for (I=0;I<argc;I++)j=j + atoi(argv[I]);printf("%d",j);}1236123 Compilation error <------ansFundamentals of Programming27 The programming language that was designed for specifying algorithmAddressASCIIALGOLNone of these options28 _____ contains the addresses of all the records according to the contents of the field designed as the record key.Index <------ans SubscriptArrayFile29 _________ symbol is used for Processing of data.OvalParallelogram <------ansRectangle Diamond30 __________ is the analysis tool used for planning program logicProtocolNone of these optionsPROLOGPseudocode31 Machine language has two part format the first part is__________ and the second part is __________OPCODE,OPERAND<------ansOPERAND,OPCODE DATA CODE,OPERANDOPERAND,CODEOP32 Language Primarily used for internet-based applicationsADAC++JAVA <------ansFORTRAN33 _________ is a point at which the debugger stops during program execution and awaits a further command.Memory DumpWatch point <------ansBreak pointNone of these options34 ________do not contain any program logic and are ignored by the language processor.ProtocolVirusCommentNone of these options35 The component of data base management system is ________Data definition LanguageData manipulation LanguageData definition Language and Data manipulation LanguageNone of these options36 The quality of Algorithm is judged on the basis of_________Time requirementMemory RequirementAccuracy of solutionAll of these options <------ans37 Advantages of using flow charts isEffective AnalysisEfficient CodingTime consumingEffective Analysis and Efficient Coding <------ans Provided by www.YuvaJobs.com - CDAC Whole Testpaper