Java | JSP | JSF Answers

Questions answered by Experts: 3 611

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search

1. Write pseudo code that prints the smallest value among a list of numbers. (10 marks) 


The assignment will contain 4 departments as four different object classes



i) Super Department



ii) Admin Department



iii) Hr Department



iv) Tech Department




Unit 4 Programming Assignment In this assignment, you will again modify your Quiz program from the previous assignment. You will create a separate class for quiz questions, and you will create objects of that class to ask questions and check answers. This assignment will include multiple cut-and-paste operations from the existing "Quiz" class into the new "MultipleChoiceQuestion" class. Object-oriented programming is designed to avoid cut and paste, and you will see some of the techniques for re-using existing code in the next assignment. In this assignment, however, you will be converting from procedural programming to object-oriented programming, and cut-and-paste is a simple strategy for this conversion.


Give an example of a class and an example of an object. Describe what a class is, what an object is, and how they are related. Use your examples to illustrate the descriptions.

Your Discussion should be at least 250 words in length, but not more than 750 words. 


The class shown below keeps track of a pressure sensor in a laboratory. When a Sensor object is created using the first constructor, the initial pressure is set to zero. When it is created using the second constructor it is set to the value of the parameter. The pressure should not be set to a value less than zero. Therefore, if the input parameter to the setPressure method is a negative number, the pressure should not be changed and a value of false should be returned. If the pressure is set successfully, a value of true should be returned. (a) Write the code for the Sensor class. (b)


Make a class student. The student class has data members such a sroll number, name, branch. Create a class called exam that has data members roll number and six subject marks. Derive the result class from student and exam it has own data members such a total mark, and result. Write a Java program to model the relationships.


Input

A line containing an integer.

35

Output

A line containing a string.

Out





Design an application that will allow a user to keep track of the amount of tennis matches won by three professional tennis players. The user should be presented with a menu using the numbers 1, 2 and 3 that corresponds to the tennis players below. Tennis Players: 1. Novak Djokovic 2. Andy Murray 3. Roger Federer Prompt the user to choose a tennis player who has won a match from the menu using the numbers 1, 2 or 3; else the user enters 0 to quit. If the user chooses 1, 2 or 3, show the input section again and if the user then chooses 0, show a breakdown of the amount of matches won by each tennis player. Please note that menu items appear in the Console window. Menu items do not need to be created. Your output should also display the amount of games that have been captured. Make use of a method to get the input from the user and another method to increment the games won by the player. In your solution make provision for if a user has entered in an invalid tennis player number. 


Design a Java application that will allow a user to capture the top students for a module. Allow the


user to enter in the module name, followed by the number of students the user would like to


capture.


Continue to capture the results for the number of students entered. Once all the student results


have been captured create a results report.


In the results report display the student results entered, a student count and the average result


obtained.



At Mr. G school of Programming, the final school fees to be paid is calculated as follows.




Original Fees should be greater than or equal to R50 000



Minimum fixed deposit of R10 000



If deposit is greater than pr equal to half the original fees, you get a 5% discount from the original fees



Final total fees will also include the following



School Levy is 10% of original fees



Sports fee is 5% of original fees.



Write a program the calculates the final total fees to be paid.




Program must request user to enter original fees value greater then R50 000.




Program should also request user to enter amount to deposit before calculating final total fees.

LATEST TUTORIALS
APPROVED BY CLIENTS