Question: Q . 1 . SET A Write a program to create a class called Divisors. Divisors has a method ( printdivisors ) to print all
Q SET A
Write a program to create a class called Divisors. Divisors has a
methodprintdivisors to print all divisors for a given number. Write a Java program
to create three threads and all of them share same object of Divisors class.
Thread has to print divisors of
Thread has to print divisors of
Thread has to print divisors of
Please ensure that thread outputs are overlapped while printing the divisors using
two thread synchronization approaches method and block level
Marks
Q SET
A Shell Company Razen is recruiting the workers for daily wages. To recruit them,
the company consider only the age. The valid age to work in the company is between
to You are asked to create a code in Java for recruiting the employees. The
code should display "Permitted to work at Shell!!!" if the age is between to
Otherwise it has to throw your own exception class InvalidAgeException object
displaying "Not Permitted to work at Shell!!!".
Marks
Q SET
Assume that a file named "Employee.dat" contains Employee records Each
employee record contains Empld,EmpName, Designation and NetSalary. Write a
Java program to read an Employee Id and display the details of the Employee
Marks
Q SET
Assume that a linked list contains Strings. Write a Java program to read a
character C and count the number of strings that has the character C in the
Middle.
Marks
Q SET A
For the upcoming examination, a student has two subjects Subject and Subject
A student can prepare any of the subjects by creating an instance for the
corresponding subject class. He She may learn the subjects more one than time in
a day. Write a Java program to display which of these courses are learned more on a
particular day.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
