Vous êtes sur la page 1sur 7

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.

com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

TITLE: ThoughtWorks Sample Programming Placement Paper Level1 (Bolded option is your answer) 1. What does the following declaration mean? A ptr is a pointer to an array of 10 integers 2. In which numbering system can the binary number 1011011111000101 be easily converted to? A Hexadecimal system 3. "A pointer to an array of three chars". A char (*ptr)[3]; 4. "A pointer to a function which receives nothing and returns nothing". A void (*ptr)() 5. Which is the correct order of mathematical operators ? A Division, Multiplication, Addition, Subtraction 6. What are the types of linkages? A External, Internal and None

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

7. How would you round off a value from 1.66 to 2.0? A ceil(1.66) 8. When we mention the prototype of a function? A Declaring 9. _________correctly shows the hierarchy of arithmetic operations in C? A/*+10. We want to round off x, a float, to an int value, The correct way to do is A y = (int)(x + 0.5) 11. What will you do to treat the constant 3.14 as a float? A use 3.14f 12. _________operations can be performed on the file "NOTES.TXT" using the below code? A Read and Write 13. What is stderr ? A standard error streams
Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

14. What will the function randomize() do? A returns a random number generator with a random value based on time. 15. Specify the 2 library functions to dynamically allocate memory? A malloc() and calloc() 16. The library function used to find the last occurrence of a character in a string is A strrchr() 17. What is the similarity between a structure, union and enumeration? A All of them let you define new data types 18. _________statements is correct about an Exception? A It occurs at run-time. 19. _________is the Object Oriented way of handling run-time errors? A Exceptions 20. A class implements two interfaces each containing three methods. The class contains no instance data. Which of the following correctly indicate the size of the object created from this class?
Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

A 24 bytes 21. _________is NOT a namespace in the .NET Framework Class Library? A System.Process 22. ____________is absolutely neccessary to use a class Point present in namespace Graph stored in library? A Add Reference of the library before using the Point class. 23. _________CANNOT belong to a C#.NET Namespace? A interface 24. ________tatements is correct about the C#.NET A A value 1 will be assigned to d. 25. Suppose n is a variable of the type Byte and we wish to put OFF its third bit without disturbing any other bits A n = n & 0XF7 26. If s1 and s2 are references to two strings, then_______is the correct way to compare the two references? A s1.Equals(s2) 27. What is the most restrictive access modifier that will allow members of one class to have access to members of another class in
Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

the same package? A default access 28. Which cause a compiler error? A int [ ][ ] scores = {2,7,6}, {9,3,45}; 29. ____________class level (nonlocal) variable declarations will not compile? A private synchronized int e; 30. Which is a valid declaration within an interface? A public static short stop = 23; 31. What allows the programmer to destroy an object x? A Only the garbage collection system can destroy an object. 32. ________ is true about a method-local inner class? A It can be marked abstract. 33. ____________would compile without error? A int a = Math.abs(-5);
Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

34. ___________contains only Java programming language keywords? A goto, instanceof, native, finally, default, throws 35. Which is a valid keyword in java? A interface 36. ___________will declare an array and initialize it with five numbers? A int [] a = {23,22,21,20,19}; 37. __________is a valid declaration of a boolean? A boolean b3 = false; 38. Which is a valid declarations of a String? A String s1 = null; 39. You need to store elements in a collection that guarantees that no duplicates are stored. ___________interfaces provide that capability? A Java.util.Map 40. Which collection class allows you to associate its elements with key values, and allows you to retrieve objects in FIFO (first-in, first-out) sequence?

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

A java.util.LinkedHashMap

Visit www.latestoffcampus.com for placement papers, interview tips & job updates. Toget freeupdates tomail http://groups.google.com/group/latestoffcampus/subscribeLive updates on Facebook @ www.facebook.com/LatestOffCampus

Vous aimerez peut-être aussi