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
cupoosta [38]
3 years ago
11

If apples are currently $4.99 a dozen, create a program that will determine the cost of any number of apples. Make the cost of a

dozen apples a variable as well, so that it can easily be changed if the price of apples changes.
Computers and Technology
1 answer:
CaHeK987 [17]3 years ago
7 0

Answer:

Explanation:

The following code is written in Java, it takes the cost of a dozen apples as a variable (costPerDozen), it then asks the user for the total number of apples that is places in a variable called (numberOfApples). It then calculates the total cost of the apples by dividing the costPerDozen by 12 and then multiplying by the total nuumber of apples requested. Finally it prints out the total.

 public static void main(String[] args) {

       double costPerDozen = 4.99;

       Scanner input = new Scanner(System.in);

       System.out.println("How many apples would you want?");

       int numberOfApples = input.nextInt();

       double totalCost = (costPerDozen / 12) * numberOfApples;

       System.out.println("That will cost: " + totalCost);

   }

You might be interested in
To reduce chances of system failure, engineers may use _____ .
Nataliya [291]
<span>To reduce chances of system failure, engineers may use process control. This is a system which involves activities that ensures the whole process variables can be predicted and controlled to prevent failure. This involves the use of safety valves and sensors.</span>
5 0
3 years ago
Read 2 more answers
DMA controllers ____.A) do not utilize an additional, special purpose, processorB) are a nonstandard component in PCs of todayC)
otez555 [7]

Answer:

D) can access main memory at the same time as the main CPU

Explanation:

DMA is short for Direct Memory Access, these controllers allow the device to transfer data directly to and from the memory modules without interfering with CPU processes. Therefore it can access main memory at the same time as the main CPU. Thus freeing up CPU processing power for other tasks while also retrieving the data necessary.

8 0
3 years ago
You discover memory is corrupted, what would be an indication of a software vs. a hardware issue?
bearhunter [10]
Hey there!

Memory (RAM) is considered to be hardware since it is a physical component that makes up the computer and is accessed through the CPU rather than internal code that makes the computer run (which is software). Therefore, if you are having issues with the memory, it is likely a problem with a memory chip, making it a hardware issue. 

Hope this helped you out! :-)
8 0
3 years ago
With which game is shigeru miyamoto associated
Juliette [100K]

Answer: Mario, Donkey Kong, and Legend of Zelda.

To be honest those are not the only games that Shigeru Miyamoto is associated with, but these are the games that he is most known for. Shigeru Miyamoto is a video game designer and producer who works for the Nintendo company.

These games mentioned are just some of the games that he helped produce for the company. He started working for the Nintendo company on 1977 and helped with the production of multiple games after joining the company. He initially started working in the Nintendo company as a manga artist, but then moved on to help design and produce different video games.

4 0
3 years ago
Does anyone know how to change there Name of the account that shows up? If you do please tell me in a comment and/or Answer.
Alona [7]

Answer:

change your email

Explanation:

award me brainliest

6 0
3 years ago
Read 2 more answers
Other questions:
  • Morgan is the operations manager for a national appliance distributor. The company has offices throughout the United States. Com
    7·1 answer
  • A typeface in which each character has the same width and is often used to display programming code is _
    8·1 answer
  • Select the correct answer.
    5·1 answer
  • Google’s adwords system provides a quality score as a measure of _____, which indicates the usefulness of an ad message to consu
    6·1 answer
  • Which popular file format loses some of the information from the image? JPEG TIFF RAW NEF
    12·1 answer
  • One student will be stationed near you in a coffee shop. The other student will be located two miles away from your school. You
    10·2 answers
  • What is the output?
    7·1 answer
  • Which of the following statement is correct ? A . potential difference is measured by ammeter . B . The unit of potential differ
    9·1 answer
  • The following is a function:
    6·1 answer
  • What do you think that private information like passwords pin number will be guarded or shared with the public? why?
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!