Nothing Special   »   [go: up one dir, main page]

Remid Question Bank-OOPJ

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

Question Bank for Remid Exam (October-2019)

Subject Name : Object Oriented Programming using Java (2150704)

Unit-7: Multithreading
1. Explain Thread life cycle.
2. What is multithreading? What are the ways in which you can create a thread? Explain it with
example.
3. Explain Thread class and its methods (static and instance) with example.
4. List and explain methods for Inter-thread communication (cooperation).
5. Explain two usage of keyword synchronized.

Unit-8: IO Programming
6. Discuss Byte Stream and Character Stream class.
7. Explain File class and its methods with example.
8. Explain FileInputStream and FileOutputStream class and its methods with example.
9. Explain FileReader and FileWriter class and its methods with example.
10. Differentiate : Text I/O and Binary I/O

Unit-9: Collection classes


11. Write a note on „Collection in JAVA‟.
12. What is Collection framework? What are the advantages of it?
13. Explain Iterator interface and its methods with example.
14. Explain Enumeration interface and its methods with example.
15. Explain ListIterator interface and its methods with example.
16. Explain List interface and its methods with example.
17. Explain utility class ArrayList and its methods with example.
18. Explain utility class LinkedList and its methods with example.
19. Explain utility class Vector and its methods with example.
20. Explain utility class Stack and its methods with example.
21. Explain utility class Properties and its methods with example.
22. Explain utility class HashSet and its methods with example.
23. Explain utility class TreeSet and its methods with example.
24. Explain utility class LinkedHashSet and its methods with example.
25. Explain utility class HashMap and its methods with example.
26. Explain utility class PriorityQueue and its methods with example.
27. Explain utility class Random and its methods with example.
28. Define generics in java. Write a program to demonstrate generic interface and generic method.

Unit-10: Networking with java.net


29. Explain InetAddress class and its methods with example.
30. Write a program using concept of TCP.
31. Write a program using concept of UDP.
32. Differentiate : Socket and ServerSocket

Unit-11 to Unit-15:
33. Draw class diagram with the help of an example.
34. Draw use case diagram with the help of an example.
35. Draw activity diagram with the help of an example.
36. Draw state diagram with the help of an example.
37. Draw sequence diagram with the help of an example.
Sample Programs from GTU papers:
1. Write a program for producer-consumer problem using Thread concept.
2. Write a program that reads file name from user, through command line argument or from user and
displays/reads content of the text file on console.
3. Write a program that accepts name of website from user, and displays IP address of it on console.
4. Create a class called Student. Write a student manager program to manipulate the student
information from files by using the BufferedReader and BufferedWriter.
5. Write a program that reads a file and counts the number of occurrences of digit 5. Supply the file
name as a command-line argument.
6. Write a program to create two thread one display alphabet from a to z and other will display
numbers from 1 to 100.
7. Write a program that counts number of characters, words, and lines in a text file.
8. Write a program to check whether the name given from command line is file or not. If it is a file
then print the size of a file and if it is a directory then it should display the name of all files in it.
9. Write a program using BufferedInputStream, FileInputStream, BufferedOutputStream,
FileOutputStream to copy content of one file Test1.txt into another file Test2.txt.
10. Write a program to create two threads, one thread will check whether given number is prime or not
and second thread will print prime numbers between 0 and 100.
11. Write a program which read source file and destination file name and copy the content of source
file to destination file.
12. Write a program that executes two threads. One thread displays "Welcome" every 1000
milliseconds & another thread displays "Good Bye" every 5000 milliseconds. Create the threads by
implementing the Runnable interface.
13. Write a program to implement a singly linked list with nodes storing integer information using
suitable utility class.
14. Write a program to replace all “word1” by “word2” to a file without using temporary file and
display the no. of replacement.
15. Write a program that executes two threads. One thread displays "Good Morning" every 1000
milliseconds & another thread displays "Good Afternoon" every 3000 milliseconds. Create the
threads by implementing the Runnable interface.
16. Write a program to read employee salary and calculate the income tax based on 10% of income and
store it in tax.txt file for five different employees.
17. Write a program which read numbers from number.txt file and store even number to even.txt and
odd number into odd.txt file.

You might also like