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
gregori [183]
3 years ago
6

This code snippet is intended to calculate the balance of an account after twenty years of gaining interest. Select the statemen

t that correctly completes the loop.
int years = 20;
double balance = 10000;
while (years > 0)
{
__________
double interest = balance * rate / 100;
balance = balance + interest;
}
Computers and Technology
1 answer:
Firlakuza [10]3 years ago
8 0

Answer:

The answer to this question is the "years--;".

Explanation:

In the given question code the if we define the years--; and the rate of interest in the code so this program will return a value for example if we give rate of interest or rate to value 5 then the output of the code is 26532.977051  because it returns the double that is a floating-point value.  So the missing code for this question is "years--;".

 

You might be interested in
In your own words, explain the FNAF timeline
tatiyna

Answer:

see shawty problem is, I havent had that phase yet, my cousin would be able to answer this tho

3 0
3 years ago
How are natural systems and engineered systems similar to one another?
erastovalidia [21]

They get the idea from nature and then the make engineered systems.That is how they are similar.

4 0
3 years ago
Write an algorithm to print the minimum and maximum of an integer array. Your need to pass the array as a parameter. Since we ca
sammy [17]

Answer:

See explaination

Explanation:

MinMax.java

import java.util.*;

public class MinMax

{

static void MinMax(int[] arr)

{

int Min=arr[0]; // initializinf min and max with 1st value of array

int Max=arr[0];

for(int i=0;i<arr.length;i++) // iterating loop only once

{

if(arr[i]>Max) // checking max value

{

Max=arr[i];

}

if(arr[i]<Min) // checking min value

{

Min=arr[i];

}

}

System.out.println("Min Number is "+Min); //printing min value

System.out.println("Max Number is "+Max); //printing max value

}

public static void main(String[] args) {

Scanner sc = new Scanner(System.in);

System.out.print("Enter N value: "); // taking n value

int n=sc.nextInt();

int[] arr=new int[n];

System.out.println("Enter N elements:"); // taking n elements into array

for(int i=0;i<n;i++)

{

arr[i]=sc.nextInt(); // each element into the array

}

MinMax(arr); // calling MinMax() method.

}

}

4 0
3 years ago
I have a question involving do and for loops while using arrays.
larisa86 [58]

Answer:

i just got my new pc

Explanation:

5 0
3 years ago
D. A................ usually contains detailed comments about something in the text.
kondaur [170]

Answer: Foot note

Explanation:

The option that contains detailed comments about something in the text is simply referred to as the foot note.

A footnote is simply refered to as the note that is at the bottom of a particular page which gives more information about a particular thing.

Therefore, based on the options given, the answer is B.

7 0
2 years ago
Other questions:
  • The Windows Group Policy feature provides __________ that govern the way Windows operates in enterprise environments. a. a centr
    8·1 answer
  • An online company wants to conduct real-time sentiment analysis about its products from its social media channels using SQL.
    12·1 answer
  • Write a program that converst the temperature from Celcius to Fahrenheit. The formula is: F (9/5)C+32
    12·2 answers
  • The computer addicts are conscious about their addiction. True or false
    9·1 answer
  • 9. Government and corporate officials concerned about security threats do not bring their own cell phones or laptops when travel
    9·1 answer
  • A binary message consisting of four bits was sent to you by a friend. The message was supposed to be ABAB. Unfortunately, your f
    8·1 answer
  • Name a piece of software you often use where it is easy to produce an error. Explain ways you could improve the interface to bet
    5·1 answer
  • What is the full from of CPU?​
    5·2 answers
  • ....is an act of introducing an invention into market on business basis for profit​
    12·1 answer
  • Can someone help me with python
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!