0% found this document useful (0 votes)
637 views17 pages

Aptitude Questions

Uploaded by

vighneshvg07
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
637 views17 pages

Aptitude Questions

Uploaded by

vighneshvg07
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 17

Aptitude Questions

1.A train running at the speed of 60 km/hr crosses a pole in 9


seconds. What is the length of the train?

a.120 metres b.180 metres


c.324 metres d.150 metres

Answer: d

2.Two trains running in opposite directions cross a man standing on the


platform in 27 seconds and 17 seconds respectively and they cross each other in
23 seconds. The ratio of their speeds is:
a. 1 : 3 b. 3 : 2
c. 3 : 4 d. None of these

Answer: b

3.If a person walks at 14 km/hr instead of 10 km/hr, he would have


walked 20 km more. The actual distance travelled by him is:
a.50 km b.56 km
c.70 km d.80 km

Answer: b

4.Excluding stoppages, the speed of a bus is 54 kmph and


including stoppages, it is 45 kmph. For how many minutes does the
bus stop per hour?

a. 9 b. 10
c. 12 d. 20

Answer: b
5.A car travelling with of its actual speed covers 42 km in 1 hr 40
min 48 sec. Find the actual speed of the car.
a.100 km/hr b. 25 km/hr
c. 30 km/hr d.35 km/hr

Answer: d

6.Robert is travelling on his cycle and has calculated to reach point


A at 2 P.M. if he travels at 10 kmph, he will reach there at 12 noon if
he travels at 15 kmph. At what speed must he travel to reach A at 1
P.M.?
a. 8 kmph b. 11 kmph
c. 12 kmph d. 14 kmph

Answer: c

7.The man to who I sold my house was a cheat.


a.to whom I sell b.to who I sell
c. who was sold to d.to whom I sold
Answer: d

8.They were all shocked at his failure in the competition.


a. were shocked at all b. had all shocked at
c. had all shocked by d. had been all shocked on
e. No correction required

Answer: e

*All the best*


9.Tanya is older than Eric.
Cliff is older than Tanya.
Eric is older than Cliff.
If the first two statements are true, the third statement is
a. true b. false
c. uncertain

Answer: b

10. Mara runs faster than Gail.


Lily runs faster than Mara.
Gail runs faster than Lily.
If the first two statements are true, the third statement is
a. true c. uncertain
b. false

Answer: a

11. The Kingston Mall has more stores than the Galleria.
The Four Corners Mall has fewer stores than the Galleria.
The Kingston Mall has more stores than the Four Corners Mall.
If the first two statements are true, the third statement is
a. true c. uncertain
b. false

Answer: a
12. Which of the following statements should be used to obtain a
remainder after dividing 3.14 by 2.1 ?
a. rem = 3.14 % 2.1; c. rem = fmod(3.14, 2.1);
b. rem = modf(3.14, 2.1);
d. Remainder cannot be obtain in floating point division.
Answer: c

13.What are the types of linkages?


a. Internal and External b. External, Internal and None
c. External and None d. Internal
Answer: b

14. Which of the following special symbol allowed in a variable


name?
a. * (asterisk) b. | (pipeline)
c. - (hyphen) d. _ (underscore)
Answer: d

15. How would you round off a value from 1.66 to 2.0?
a. ceil(1.66) b. floor(1.66)
c. roundup(1.66) d. roundto(1.66)
Answer: a

16. Which of the following type of class allows only one object of it
to be created?
a. Virtual class b. Abstract class
c. Singleton class d. Friend class
Answer: c
17. Which of the following is not a type of constructor?
a. Copy constructor b. Friend constructor
c. Default constructor d. Parameterized constructor
Answer: b

18. Which of the following is not the member of class?

a. Static function b. Friend function


c. Const function d. Virtual function

Answer: b

19. Which of the following concepts means determining at runtime


what method to invoke?
a. Data hiding b. Dynamic Typing
c. Dynamic binding d. Dynamic loading

Answer: c

20. Which of the following concepts of OOPS means exposing only


necessary information to client?
a. Encapsulation b. Abstraction
c. Data hiding d. Data binding

Answer: c

21. How many types of polymorphisms are supported by C++?


a. 1 b. 2
c. 3 d. 4

Answer: b

*All the best*


22. Which of the following is an abstract data type?
a. int b. double
c. string d. Class

Answer: d

23.Which of the following approach is adapted by C++?


a. Top-down b. Bottom-up
c. Right-left d. Left-right

Answer: b

24. Which interface does java.util.Hashtable implement?


a. Java.util.Map b. Java.util.List
c. Java.util.HashTable d. Java.util.Collection

Answer: a

25. Which is valid declaration of a float?


float f = 1F;
float f = 1.0;
float f = "1";
float f = 1.0d;

Answer: a

26. What is the numerical range of char?


a. 0 to 32767 b. 0 to 65535
c. -256 to 255 d. -32768 to 32767

Answer: b
class HappyGarbage01
{
public static void main(String args[])
{
HappyGarbage01 h = new HappyGarbage01();
h.methodA(); /* Line 6 */
}
Object methodA()
{
Object obj1 = new Object();
Object [] obj2 = new Object[1];
obj2[0] = obj1;
obj1 = null;
return obj2[0];
}
}

27. Where will be the most chance of the garbage collector being
invoked?
a. After line 9 b. After line 10
c. After line 11
d. Garbage collector never invoked in methodA()
Answer: d

28. You want subclasses in any package to have access to


members of a superclass. Which is the most restrictive access that
accomplishes this objective?
a. public b. private
c. protected d. transient
Answer: c
29. Which of the following is/are legal method declarations?
1. protected abstract void m1();
2. static final void m1(){}
3. synchronized public final void m1() {}
4. private native void m1();
a. 1 and 3 b. 2 and 4
c. 1 only d. All of them are legal declarations.
Answer: d

30. Which two cause a compiler error?


1. float[ ] f = new float(3);
2. float f2[ ] = new float[ ];
3. float[ ]f1 = new float[3];
4. float f3[ ] = new float[3];
5. float f5[ ] = {1.0f, 2.0f, 2.0f};
a. 2, 4 b. 3, 5
c. 4, 5 d. 1, 2
Answer: d

31. Given a method in a protected class, what access modifier do


you use to restrict access to that method to only the other members
of the same class?
a. final b. static
c. private d. protected
Answer: c

*All the best*


32. Which is a valid declaration within an interface?
a. public static short stop = 23; b. protected short stop =23;
c. transient short stop = 23; d. final void madness(short stop);

Answer: a

33. The SQL command to create a table is:


a. MAKE TABLE. b. ALTER TABLE.
c. DEFINE TABLE. d. CREATE TABLE.

Answer: d

34. The DROP TABLE statement:


a) deletes the table structure only.
b) deletes the table structure along with the table data.
c) works whether or not referential integrity constraints would be
violated.
d) is not an SQL statement.

Answer: b

35. The SQL statement to create a view is:


a) CREATE VIEW.
b) MAKE VIEW.
c) SELECT VIEW.
d) INSERT VIEW.

Answer: a
36. Which of the following is NOT a type of SQL constraint?
a) PRIMARY KEY
b) FOREIGN KEY
c) ALTERNATE KEY
d) UNIQUE

Answer: c

37. What will be the output of the program?

public class Foo


{
public static void main(String[] args)
{
try
{
return;
}
finally
{
System.out.println( "Finally" );
}
}
}
a) Finally
b) Compilation fails.
c) The code runs with no output.
d) An exception is thrown at runtime.
Answer: a
38. What will be the output of the program?

try
{
int x = 0;
int y = 5 / x;
}
catch (Exception e)
{
System.out.println("Exception");
}
catch (ArithmeticException ae)
{
System.out.println(" Arithmetic Exception");
}
System.out.println("finished");

a) finished
b) Exception
c) Compilation fails.
d) Arithmetic Exception

Answer: c

39.
Select the alternative which represents three out of the five
alternative figures which when fitted into each other would form a
complete square.

a) 145
b) 245
c) 123
d) 234
Answer: b
40. The banker's discount on a bill due 4 months hence at 15% is
Rs. 420. The true discount is:
a) Rs. 400
b) Rs. 360
c) Rs. 480
d) Rs. 320
Answer: a

41. The three-schema components include all, but:


a) internal schema.
b) conceptual schema.
c) programming schema.
d) external schema.
Answer: c

42. Which is not a type of data management technology?


a) Relational
b) Rational
c) Object-oriented
d) Dimensional

Answer: b

43. Strategic Planning factors do not include which of the following?


a) Organizational goals
b) Critical success factors
c) Information engineering
d) Problem areas

Answer: c

*All the best*


44. Which word does NOT belong with the others?
a) parsley
b) basil
c) dill
d) mayonnaise
Answer: d

45. Which word does NOT belong with the others?


a) rye
b) sourdough
c) pumpernickel
d) loaf
Answer: a

46. Which of these keywords is used to define interfaces in


Java?
a) intf
b) Intf
c) interface
d) Interface
Answer: c

47. Which of the following is the superclass of all Java classes?


a) Array List
b) Abstract Class
c) Object class
d) String
Answer: c
48. Which of these keywords is used to block an
exception?
a) check
b) throw
c) catch
d) try
Answer: d

49. Total constructor string class have?


a. 3
b. 7
c. 13
d. 20

Answer: c

50. When is the finalize() method called?


a. Before Garbage Collection
b. Before an object goes out of scope
c. Before a variable goes out of scope
d. None

Answer: a

51. What is Runnable?


a. Abstract class
b. Interface
c. Class
d. Method
Answer: b
52. Which of the following is not an access modifier?
a) Protected
b) Void
c) Public
d) Confidential
Answer: d

53. What part is used to compile, debug and execute java programs?
a) JRE
b) JIT
c) JDK
d) JVM
Answer: c

54.
Which three form part of correct array declarations?
1. public int a [ ]
2. static int [ ] a
3. public [ ] int a
4. private int a [3]
5. private int [3] a [ ]
6. public final int [ ] a
a. 1, 3, 4
b. 2, 4, 5
c. 1, 2, 6
d. 2, 5, 6

Answer: c
55. public class Test { }
What is the prototype of the default constructor?
a. Test( )
b. Test(void)
c. public Test( )
d. public Test(void)

Answer: c

56. You want a class to have access to members of another class


in the same package. Which is the most restrictive access that
accomplishes this objective?
a. public
b. private
c. protected
d. default access

Answer: d

57. Which of the following class level (nonlocal) variable


declarations will not compile?
a. protected int a;
b. transient int b = 3;
c. private synchronized int e;
d. volatile int d;

Answer: c

*All the best*


58. I told him that he was not working hard.
a. I said to him, "You are not working hard."
b. I told to him, "You are not working hard."
c. I said, "You are not working hard."
d. I said to him, "He is not working hard."

Answer: a

59. She said that her brother was getting married.


a. She said, "Her brother is getting married."
b. She told, "Her brother is getting married."
c. She said, "My brother is getting married."
d. She said, "My brother was getting married."

Answer: c

60. Y is in the East of X which is in the North of Z. If P is in the


South of Z, then in which direction of Y, is P?
a. North
b. South
c. South-East
d. None of these

Answer: d

*All the best*

You might also like