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
nevsk [136]
3 years ago
6

What’s the difference between an entry-condition loop and an exit-condition loop? Which kind is each of the C loops? Provide a d

etailed response with examples
Computers and Technology
1 answer:
egoroff_w [7]3 years ago
7 0

Explanation:

The difference between entry condition loop is and exit - condition loop is that the entry condition loops first checks the condition to enter the loop body if the condition true then the loop body is executed otherwise loop body is not executed while the exit-condition loops first executes the loop body and then the condition for the loop is checked.

There are three loops in C that are as following:-

  1. For
  2. While
  3. Do While

Among these three loops While and For loops are entry condition loops and Do While loop is exit condition loop.

For example:-

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

{

    printf("%s","John Doe\n");

}

If the initial value of i should have been 10 then loop body didn't had executed.

int i=0;

while(i<4)

   {

       printf("%s","John Doe\n");

   }

If you try to run this while loop nothing will print on the screen because the condition is false.So the compiler will not enter the loop body and will skip over it.

int i=5;

   do{

       printf("%s","John Doe\n");

   }while(i<4);

Even if the condition is false.You will see that the John doe have been printed one time on the screen because first the body is executed then the condition is checked.

You might be interested in
The density of mercury is 13.6 grams per cubic centimeter. Complete the steps for converting 13.6 g/cm3 to kg/m3.
jek_recluse [69]
The density of mercury is 13.6 grams per cubic centimeter. Complete the steps for converting 13.6 g/cm3 to kg/m3.

(1 kg = 1,000 g, 1 m3 = 106 cm3)

13,600
106
1,360
1 g
1 kg
1 m3
7 0
2 years ago
Modern ancestor of the typewriter
Rashid [163]
I would think Microsoft Word would be the answer. It does everything a typewriter can.
4 0
3 years ago
Read 2 more answers
Kiara is using her software's graphic formats to create a line graph. As she
Ad libitum [116K]

Correct the data she entered , and the software will adjust the graph -apex

5 0
3 years ago
Read 2 more answers
What are Operating Systems?
horrorfan [7]

Answer:

the software that supports a computer's basic functions, such as scheduling tasks, executing applications, and controlling peripherals.

5 0
2 years ago
Does anyone know the code for codeHS 5.4.7 teenagers?
Over [174]

Answer:

function start(){

var age = readInt("Age: ");

if(age == 15){

println("Yes, you are a teenager.");

}else{

println("No, you are not a teenager.");

}

}

Explanation:

6 0
3 years ago
Other questions:
  • You use the _____ sheet in the format cells dialog box to position data in a cell by centering it, for example.​
    8·1 answer
  • Manuel is working on a project in Visual Studio. He wants to keep this program showing on the entire desktop, but he also needs
    7·1 answer
  • How to find i with superposition method
    8·1 answer
  • Which of these jobs would be most appropriate for someone who majors in information technology? managing a database for a large
    6·2 answers
  • The ____ developed numerical methods for generating square roots, multiplication tables, and trigonometric tables used by early
    12·1 answer
  • In this challenge, write a function to add two floating point numbers. Determine the integer floor of the sum. The floor is the
    8·1 answer
  • The visitor's age is stored in the variable age, the day of the week is stored in a variable day, and the price in dollars is st
    8·1 answer
  • When a Select Case statement executes, the value of the test expression is compared with the values that follow each of the ____
    7·1 answer
  • To solve the difficulty of scaling memory organization, memories are physically organized into a ____-dimensional organization.
    9·1 answer
  • Hexadecimal to denary gcse method
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!