Basics of Computer Languages

This test consists of questions related to computer languages, database, data structures and operating system etc.

20 Questions Published

Questions

Question 1 Multiple Choice (Single Answer)

Which of the following is a true statement in java?

  1. Static block is always executed when the JVM loads the class in java.
  2. Static method can be synchronized in java.
  3. We can throw exception in a static block.
  4. All of the above are true.
  5. Only (1) and (3) are true.
Question 2 Multiple Choice (Single Answer)

Which of the following statement(s) is/are true in java?

  1. An interface can not have static method in java.
  2. We can declare abstract class without any abstract method in java.
  3. If we declare main method as private in java then the program will compile.
  4. All of the above.
  5. Only (1) and (3) are true.
Question 3 Multiple Choice (Single Answer)

Which of the following method of the HashMap returns the number of number of key-value mappings in the map?

  1. Set entrySet()
  2. Set keySet()
  3. int size()
  4. boolean isEmpty()
  5. None of the above
Question 4 Multiple Choice (Single Answer)

Which of the following constructor of the HashMap gives NullPointerException in the java collection framework?

  1. HashMap (Map m)
  2. HashMap (int initialCapacity)
  3. HashMap(int initialCapacity, float loadFactor)
  4. HashMap()
  5. None of the above
Question 5 Multiple Choice (Single Answer)

Which of the database schema represents the data as a set of relations?

  1. Physical data level
  2. External data level
  3. Conceptual data level
  4. Both (1) and (2)
  5. None of the above
Question 6 Multiple Choice (Single Answer)

What is the meaning of 'out' in System.out.println in java?

  1. It is a class in java.lang package.
  2. It is a static object of PrintStream class.
  3. It is a method in the PrintStream class.
  4. It is a reference variable of the System class.
  5. Both (2) and (4).
Question 7 Multiple Choice (Single Answer)

Which of the following command comes under the data manipulation language (DML) in database?

  1. Create
  2. Alter
  3. Delete
  4. Drop
  5. Grant
Question 8 Multiple Choice (Single Answer)

Which of the following class(es) belong to java.lang package?

  1. String
  2. Thread
  3. Throwable
  4. Math
  5. All of the above
Question 9 Multiple Choice (Single Answer)

What is the following determines the robustness of the java programming language?

  1. It determines that the java is error free language as it is strictly typed.
  2. It determines the multithreading support.
  3. It determines that java bytecode can run on any platform.
  4. It determines that java is widely distributed over internet.
  5. None of the above
Question 10 Multiple Choice (Single Answer)

Which of the following is not a feature of object oriented programming languages?

  1. There is mainly focus on the object.
  2. Code reusability.
  3. Data binding.
  4. Top down programming approach.
  5. None of the above
Question 11 Multiple Choice (Single Answer)

Which of the following is/are the true statement?

  1. A constructor has the same name as a class name.
  2. Destructors are used to release the resources.
  3. A constructor can be private in C++.
  4. All of the above.
  5. None of the above
Question 12 Multiple Choice (Single Answer)

Which of the following is the example of linear data structure?

  1. Tree
  2. Graph
  3. Linked list
  4. All of the above
  5. None of the above
Question 13 Multiple Choice (Single Answer)

Which of the following is/are the true statements?

  1. C++ supports null pointers.
  2. int *ptr[abs] is the example of array of pointer to an integer.
  3. In C++, we can pass pointer to a function.
  4. All of the above.
  5. Only (1) and (3) are true.
Question 14 Multiple Choice (Single Answer)

Which of the following is/are the use of database trigger in database?

  1. To replicate the data.
  2. To enforce business rules.
  3. To execute business rules
  4. All of the above.
  5. Only (1) and (2).
Question 15 Multiple Choice (Single Answer)

Which of the following is not true?

  1. Jquery uses the javascript library.
  2. Jquery supports ajax.
  3. By including jquery library files in to our project, it takes additional space on the server.
  4. Google map is the example of ajax.
  5. None of the above
Question 16 Multiple Choice (Single Answer)

Which of the property of the database transaction ensures the persistency of the database?

  1. Isolation
  2. Durability
  3. Atomicity
  4. Consistency
  5. None of the above
Question 17 Multiple Choice (Single Answer)

Which of the following is not a String function in C# language?

  1. IndexOf()
  2. ToLower()
  3. Contains()
  4. Trim()
  5. None of the above
Question 18 Multiple Choice (Single Answer)

Which of the following is/are the client side programming languages?

  1. ASP.Net
  2. JavaScript
  3. PHP
  4. Both (2) and (3)
  5. None of the above
Question 19 Multiple Choice (Single Answer)

Which of the following is an example of application software?

  1. Media player
  2. Accounting software
  3. Operating system
  4. Both (1) and (2)
  5. None of the above
Question 20 Multiple Choice (Single Answer)

Which of the following is/are the true statements(s)?

  1. Ajax uses javascript to communicate with the server.
  2. In ajax, we need not to wait the response of the server to load a particular part of the page.
  3. There is no server side request to handle in javascript.
  4. All of the above.
  5. Only (1) and (2).