answer.
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
krok68 [10]
2 years ago
13

Assume that two parallel arrays have been declared and initialized: healthOption an array of type char that contains letter code

s for different healthcare options and annualCost an array of type int. The i-th element of annualCost indicates the annual cost of the i-th element of healthOption. In addition, there is an char variable, best2.Write the code necessary to assign to best2 the health option with the lower annual cost, considering only the first two healthcare options.
Computers and Technology
1 answer:
eduard2 years ago
6 0

/*

Since we have to check the first two options only as mentioned in last part of question the loop will work 2 times only and will compare the cost of first element and second and assign the healthoption accordingly

*/

for(int i =0;i<=1;i++){

if(annualCost[i]<annualCost[i+1]

best2 = healthOption[i]

else

best2 = healthOption[i+1]

}

You might be interested in
The OSI security architecture provides a systematic framework for defining security attacks, mechanisms, and services. True or F
Alex Ar [27]

Answer:

True is the correct answer for the above question

Explanation:

  • The OSI security architecture is a security framework that is used to secure the data packets when it is going to transfer on the internet for communication.
  • It is used to define the security rules and mechanism which need to secure the data packets.
  • It mainly focuses on Security services, Security attacks, Security mechanisms.
  • The above question-statement states about the framework which defines the security mechanism to secure from the attacks are known as OSI Security architecture which is the correct statement which is described above. Hence True is the correct answer.
3 0
2 years ago
George is working with an image in Photoshop. He added a lot of effects to the image. He saved the first draft of the file. The
Alja [10]

Answer:

JPEG, PDF

Explanation:

3 0
2 years ago
Read 2 more answers
Get user input as a boolean and store it in the variable tallEnough. Also, get user input as a boolean and store it in the varia
frozen [14]

Answer:

I will code in JAVA.

import java.util.Scanner;

public class Main {

public static void main(String[] args) {

 

boolean tallEnough;

boolean oldEnough;

Scanner input = new Scanner(System.in);

tallEnough = input.nextBoolean();<em> //wait the input for tallEnough</em>

oldEnough = input.nextBoolean(); <em>//wait the input for OldEnough</em>

   if(tallEnough && oldEnough){

   System.out.print(true);

   } else {

   System.out.print(false);

   }

}

}

Explanation:

First, to accept user inputs you have to import the class Scanner. Then declare both variables before allowing the user to set input values for both boolean variables.

In the if-else statement checks if both variables are true, then prints true. Another case prints always false.

8 0
1 year ago
Which of the following is not one of the four criteria for evaluating websites?
Flura [38]

Answer:validity

Explanation:

Because it dont sound right

5 0
2 years ago
To keep a desktop computer or a server powered up when the electricity goes off in addition to protection against power fluctuat
pickupchik [31]

To keep a desktop computer or a server powered up when the electricity goes off in addition to protection against power fluctuations, an <u>uninterruptible power supply (UPS)</u>, which contains a built-in battery, can be used.

<u>Explanation</u>:

An uninterruptible power supply (UPS) is a device that allows a computer or server powered up for a short time, when the electricity goes off. UPS device also provides uninterrupted service during power fluctuation.

A battery is inbuilt in the UPS and provides power for few minutes to the computer to shut down it in a proper manner.

UPS is available at affordable cost and can be maintained at low cost compared to generators.

8 0
1 year ago
Read 2 more answers
Other questions:
  • Using information from the lesson, explain how new technologies change your experience as a consumer.
    5·2 answers
  • Linda is making handouts for her upcoming presentation. She wants the handouts to be comprehensible to people who do not attend
    12·2 answers
  • When creating a table in the relational database design from an entity in the extended e-r model, the attributes of the entity b
    13·1 answer
  • Which feature of Badoo helped members make their profile more prominent?
    14·1 answer
  • During which phase of web publishing would you use a text editor to enter codes that instruct the browser how to display webpage
    5·1 answer
  • Which item is essential to know before sketching a navigation menu flowchart? template specifics, such as horizontal or vertical
    12·1 answer
  • Compare the elements of the basic Software Development Life Cycle with 2 other models. How are they similar? How are they differ
    9·1 answer
  • When considering server consolidation, plan on running ___________ vCPUs per core.a. 1 to 2b. 3 to 4c. 4 to 6d. 6 to 8
    7·1 answer
  • The given SQL creates a Movie table with an auto-incrementing ID column. Write a single INSERT statement immediately after the C
    12·1 answer
  • A drive is small enough to be carried in one's pocket.
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!