Student
-name: String
-studentNumber: long
-loanAmount: double
+<<constructor>> Student()
+<<constructor>> Student(String, long, double)
+getName(): String
+getStudentNumber(): long
+getLongAmount(): double
+setName(String): void
+setStudentNumber(long): double
+setLoanAmount(double): void
+toString(): String
+show(): void
+interest(): double
show() method This method is void and does not have any parameters. This method displays the details of a Student object as follows:
Student details Name: Smittie
Student number: 12345
Loan amount: 10000.0
Coding for interest() method public double interest() { return loanAmount*.05; }
Write a program in Java to perform the following operations on Matrix using
multithreading. Get the required input matrix from the user and after that run
three threads to perform the following operation.
a. Addition
b. Subtraction
c. Multiplication
Write a menu driven program in Java to perform the operations on an Integer
Queue by making use of the concept of interfaces. And create custom
exceptions to deal with the following situations
A non-integer value is encountered in the queue
b. Insert operation when the Queue if full
c. Remove operation when queue is empty.
Write a java program to create an Account class and define constructors in it. Inherit Saving_Bank_Account class and Current_Bank_Account class from the Account class. Override constructors of Account class in Saving_Bank_Account and Current_Bank_Account classes. Define appropriate methods to operate these accounts. Make necessary assumptions. Give proper comment in your program to increase redability.
Write a Java Program that make use of a loop to output 10 plus signs.
Each plus sign must be separated by a space as shown in the example below: + + + + +
v> Write a Java programme (named EmployeePay.java) that calculates the weekly
pay for each of your employees based on the total number of hours they have
worked in a week using the following guidelines.
•
All employees are paid a regular hourly rate of some amount. (Determine
that amount in Ghana cedis)
•
Indicate the number of regular working hours for all employees in a week
•
Some employees occasionally work overtime and are supposed to be paid for
the hours they have worked overtime. (Determine the overtime hourly rate in
Ghana cedis. Note: Overtime hourly rate should be more than the regular
hourly rate).
•
Employees can however only do a maximum of 2 overtime hours each day
v> Write a Java programme (named EmployeePay.java) that calculates the weekly
pay for each of your employees based on the total number of hours they have
worked in a week using the following guidelines.
•
All employees are paid a regular hourly rate of some amount. (Determine
that amount in Ghana cedis)
•
Indicate the number of regular working hours for all employees in a week
•
Some employees occasionally work overtime and are supposed to be paid for
the hours they have worked overtime. (Determine the overtime hourly rate in
Ghana cedis. Note: Overtime hourly rate should be more than the regular
hourly rate).
•
Employees can however only do a maximum of 2 overtime hours each day.
Your programme should work as follows:
i. Create data fields (variables) of the appropriate data types to store all the
variables you will use
ii. When the programme runs, prompt an employee to enter the total
number of hours he/she has worked for the week.
Write a java application using the concepts of multithreading for a flower
shop where flowers are delivered based on order.
The Airplane always needs to check with the Airport to see if it has an
available runway before it's able to take off or land. Simulate the above-
mentioned scenario using multi-threading.