1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Ymorist [56]
3 years ago
10

. Carly's Catering provides meals for parties and special events. In Chapter 2, you wrote an application that prompts the user f

or the number of guests attending an event, displays the company motto with a border, and then displays the price of the event and whether the event is a large one. Now modify the program so that the main() method contains only three executable statements that each call a method as follows:
Engineering
1 answer:
klio [65]3 years ago
6 0

Answer:

Explanation:

public class Event

  public final static int PRICE_PER_GUEST = 35;

  public final static int CUT_OFF = 50;

 

  //Attributes

  private String eventNum;

  private int noOfGuest;

  private int price;

 

  /**

  * param eventNum the eventNum to set

  */

  public void setEventNum(String eventNum)

      this.eventNum = eventNum;

 

 

  /**

  * param noOfGuest the noOfGuest to set

  */

  public void setNoOfGuest(int noOfGuest)

      this.noOfGuest = noOfGuest;

      this.price = this.noOfGuest * PRICE_PER_GUEST;

 

 

  /**

  * return the eventNum

  */

  public String getEventNum()

      return eventNum;

 

 

  /**

  * return the noOfGuest

  */

  public int getNoOfGuest()

You might be interested in
What do you think the top TWO game elements are that directly contribute to player immersion?
fredd [130]
Sound (like music and background sound) and detail. The music and background sound is what sets the mood for the game. In horror games, the sound is sometimes uneasy to make the player feel anxious, and when something chases you the music turns into fast-pace and making the player scared and feel that adrenaline. The detail also is a great factor. The more realistic a game is, the more it feels like real life and determines if the player will get a real reaction from the game.
6 0
3 years ago
9. Imagine that you're performing measurements on a circuit with a multimeter. You measure a total circuit
ratelena [41]

Answer:

C

Explanation:

the total resistance is equal to the total potential difference divided by the Current

3 0
2 years ago
Read 2 more answers
What are difference between conic sectional and solids?
Murljashka [212]

Answer:

Conic Sections

a conic section is a curve which is obtained when a surface performs an intersection with a plane. The types of conic sections include hyperbola, parabola and ellipse. A circle can also be considered as a conic section.

Conic Solids on the other hand are the set of points on any segment between a region and a point which is not present in the plane of the base. They are solids with one base.

3 0
3 years ago
The Ethernet (CSMA/CD) alternates between contention intervals and successful transmissions. Assume a 100 Mbps Ethernet over 1 k
Vesnalui [34]
<h3><u>CSMA/CD Protocol: </u></h3>

Carrier sensing can transmit the data at anytime only the condition is before sending the data sense carrier if the carrier is free then send the data.

But the problem is the standing at one end of channel, we can’t send the entire carrier. Because of this 2 stations can transmit the data (use the channel) at the same time resulting in collisions.

There are no acknowledgement to detect collisions, It's stations responsibility to detect whether its data is falling into collisions or not.

<u>Example: </u>

T_{P}=1 H r, at time t = 10.00 AM, A starts, 10:59:59 AM B starts at time 11:00 AM collision starts.

12:00 AM A will see collisions

Pocket Size to detect the collision.

\begin{aligned}&T_{t} \geq 2 T_{P}\\&\frac{L}{B} \geq 2 T_{P}\\&L \geq 2 \times T_{P} \times B\end{aligned}

CSMA/CD is widely used in Ethernet.

<u>Efficiency of CSMA/CD:</u>

  • In the previous example we have seen that in worst case 2 T_{P} time require to detect a collision.
  • There could be many collisions may happen before a successful completion of transmission of a packet.

We are given number of collisions (contentions slots)=4.

\text { Propagation day }=\frac{\text {distance}}{\text {speed}}

Distance = 1km = 1000m

\begin{aligned}&\text { Speed }=2 \times 10^{8} \mathrm{m} / \mathrm{sec}\\ &T_{P}=\frac{1000}{2 \times 10^{8}}=(0.5) \times 10^{-5}=5 \times 10^{-6}\\ &T_{t}=5 \mu \mathrm{sec}\end{aligned}

7 0
3 years ago
A family member who hasn’t worked with computers before has decided to change jobs. You’ve been asked to explain some of the bas
-BARSIC- [3]
That due to the specific tasks that needs to be accomplished by each program to make an all encompassing program would be inefficient and full of bugs
6 0
3 years ago
Read 2 more answers
Other questions:
  • The number of weaving errors in a twenty-foot by ten-foot roll of carpet has a mean of 0.8 What is the probability of observing
    6·1 answer
  • What can happen to you if you are in a crash and not wearing a seat belt?<br> Explain.
    13·2 answers
  • Air enters a 200 mm diameter adiabatic nozzle at 195 deg C, 500 kPa and 100 m/s. It exits at 85 kPa. If the exit diameter is 158
    11·1 answer
  • Help Please!!!!!!!<br><br> Whatever3443<br> Please help!
    9·2 answers
  • Products. of sheet metal​
    8·1 answer
  • A manager who focuses on the employees who enable a company to do business is human resource management. True True False False
    7·1 answer
  • Select the correct answer. Felix aspires to be an engineer working for the government. What credentials will Felix require to ap
    5·1 answer
  • What is the name of the part of the expressway where cars can both enter and exit?
    15·1 answer
  • Which packet-forwarding method does a router use to make switching decisions when it is using a forwarding information base and
    5·1 answer
  • A jet of water 75m in diameter,issues with a velocity of 30m/s and impinge on a stationary plate which distort its forward motio
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!