Write a program that assigns seats on an airplane

Assignment Help JAVA Programming
Reference no: EM135146

Part-1

Prepare a program that teaches arithmetic to a young child. The program tests subtraction and addition. In Level 1 it tests only addition of numbers less than 10 whose sum is less than 10. In level 2 it tests addition of arbitrary one-digit numbers. In level 3 it tests subtraction of one-digit numbers with a non-negative difference. Generate random problems and get the player input. The player gets up to two tries per problem. Advance from one level to the next when the player has achieved a score of five points.

Part-2

Write a program that assigns seats on an airplane. Suppose the airplane has 20 seats in first class (5 rows of 4 seats each, separated by an aisle) and 90 seats in economy class (15 rows of 6 seats each, separated by an aisle). Your program could take three commands: add passengers, show seating, and quit. When passengers are added, ask for the class (first or economy) the number of passengers traveling together (1 or 2 in first class; 1 to 3 in economy), and the seating preference (window or aisle in first class; aisle, center, or window in economy). Then try to evaluate a match and assign the seats. If no match exists, print a message. Your solution should include a class Airplane that is not coupled with the Scanner or Print Stream classes.

Reference no: EM135146

Questions Cloud

Advise penguin whether they can take action against anna : In the context of the law of contract, advise Penguin Ltd whether they can take any action against Anna.
Salem management regarding tax implications : Prepare a memo to your CFO indicating the outcome of such a change on current taxes and outlining the needs for making this change and provide recommendation to Salem management regarding tax implications of this contribution.
Evaluate the correlation coefficient : Evaluate the correlation coefficient. Comment on the value of the correlation coefficient. Prepare an ANOVA table and attach the summary output.
Write a program that assigns seats on an airplane : Prepare a program that teaches arithmetic to a young child. The program tests subtraction and addition. Write a program that assigns seats on an airplane.
Prepare a java simulation program : Given a hash function h, prepare a java simulation program to determine each of the subsequent quantities after 0.8*tablesize random keys have been generated. The keys should be random integers.
Evaluating shear force and bending moment diagram : Sketch the shear force and bending moment diagram and Verify that the support reactions are correct.
Evaluate the shearing and normal stresses : Evaluate the shearing and normal stresses at points H and J located at the ends of the horizontal and vertical diameters of transverse section located 2.5 in. to the left of bearing B.
Calculate the amounts for the current year : Calculate the amounts for the current year. Calculate the amount and character of income distributed to each trust beneficiary for the year.

Reviews

Write a Review

JAVA Programming Questions & Answers

  Java program simulate a network

Java program simulate a network

  Cascading style sheet to a website

Compare and contrast the process of adding JavaScript and a Cascading Style Sheet to a Website. Determine if they can be used simultaneously in a page.

  Create a class safestack that implements a stack of strings

Create a class SafeStack that implements a stack of strings

  Develop a gui based java program

Designing and developing a College Registration program

  Design a single class that expresses the commonality

Design a single class that expresses the commonality of these concepts.

  Create a java class called samearraysexception

Create a Java class called SameArraysException that extends the Exception class.

  Java project

Prompt the user for an int between lower and upper boundary.

  Write a class that implements an ordered list of strings

In this problem you will write a class that implements an ordered list of Strings.

  Write a recursive instance method

Write a recursive instance method

  Implement the lexical and syntactic analysis

Implement the lexical and syntactic analysis of Minifun programming language.

  Develop a reliable transfer protocol over udp

Develop a reliable transfer protocol over UDP. Focus on a Stop- and-Wait protocol.

  Methods

Assignment describe the basic working of methods. How to write a method in java and how to call a method.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd