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
Triss [41]
3 years ago
7

Sara is writing a program to input her monthly phone bills and output the month name and amount for the month with maximum amoun

t. She has defined an array to hold the month names. Complete the pseudocode program. [6] # Program to output maximum month's phone bill MonthName ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"] # Define an array to hold the phone bills for each month

Computers and Technology
1 answer:
guajiro [1.7K]3 years ago
3 0

Answer:

double [] phoneBills = new double[12];

Explanation:

Since the question has requested that an array be difined to hold phone bill for each month. Above declares an array that will hold floating point number (double) and it has been created to hold 12 values representing the months January to December

Values can be added in the array as shown in the program below.

<em>public class PhoneBill {</em>

<em>    public static void main(String[] args) {</em>

<em>    String []  MonthName = {"January", "February", "March", "April", "May", "June", "July", "August",</em>

<em>            "September", "October", "November", "December"};</em>

<em>    double [] phoneBills = new double[12];</em>

<em>        phoneBills[0] = 4.5;</em>

<em>        phoneBills[1] = 4.5;</em>

<em>        phoneBills[2] = 5.5;</em>

<em>        phoneBills[3] = 6.5;</em>

<em>        phoneBills[4] = 3.5;</em>

<em>        phoneBills[5] = 5.5;</em>

<em>        phoneBills[6] = 6.5;</em>

<em>        phoneBills[7] = 7.5;</em>

<em>        phoneBills[8] = 8.5;</em>

<em>        phoneBills[9] = 4.5;</em>

<em>        phoneBills[10] = 3.5;</em>

<em>        phoneBills[11] = 7.5;</em>

<em>        System.out.println("Months and corresponding phone bill");</em>

<em>        System.out.println(Arrays.toString(MonthName));</em>

<em>        System.out.println(Arrays.toString(phoneBills));</em>

<em>    }</em>

<em>}</em>

The output of this program is attached:

You might be interested in
Which of the following does not make a good analysis class? (Points : 6) its name reflects its intent
satela [25.4K]

Answer:it has high coupling

Explanation: Coupling is the property in the field of computer program that is defined as the functions ,data and  codes of the program are dependent on each other and cannot be changed independently if requires. Thus,high amount of coupling is not considered as good factor due to high interdependence. Loose coupling can be still permitted.

Other options are correct because name of the class should reflect the purpose and well defined responsibilities should be present, modeling of certain component and high cohesion means keeping similar functions togather is also required. So, the only bad factor is high coupling

6 0
3 years ago
OSHA requires training for employees on the hazards to which they will be exposed.
Sedaia [141]

A, OSHA does require training for employees on the hazards to which they will be exposed.


3 0
4 years ago
Read 2 more answers
I’m so lost. which username do i do.
koban [17]

Answer:

the username you feel like using

5 0
3 years ago
Read 2 more answers
Most networking media send data using _____ in which data is represented by only two discrete states: 0s and 1s.
dlinn [17]

Answer:

i think digital signals

Explanation:

A digital signal is a signal that is being used to represent data as a sequence of discrete values; at any given time it can only take on one of a finite number of values.[1][2][3] This contrasts with an analog signal, which represents continuous values; at any given time it represents a real number within a continuous range of values.

6 0
3 years ago
Read 2 more answers
The _____ address range is reserved for a computer to communicate with itself and is called the loopback.
Papessa [141]
The answer is 127 I had that question before
4 0
4 years ago
Other questions:
  • How do open online courses help with independent learning? (1 point)
    13·2 answers
  • To make sure that you do not get too tired when typing for long periods, how often should you get up and stretch? Every 15 minut
    9·1 answer
  • If you're sending an email from your laptop to a classmate the laptop is the
    11·1 answer
  • With a _____ network connection, the computers and other devices on the network are physically connected via cabling to the netw
    13·1 answer
  • Help PLEASE (in attachment)
    8·1 answer
  • What do vector handles point at?
    13·2 answers
  • What is the name used for the camera s view from a single position?
    9·1 answer
  • Recall that within our BinarySearchTree class the root variable is of type BSTNode. A BSTNode object has three attributes: info
    13·1 answer
  • Compare and discuss between electromechanical and electronic era of computer​
    9·1 answer
  • Retype the below code. Fix the indentation as necessary to make the program work.
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!