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
ArbitrLikvidat [17]
3 years ago
12

(TCO 4) What will be the value of input_value if the value 5 is input at run time? cin >> input_value; if (input_value &gt

; 5) input_value = input_value + 5; else if (input_value > 2) input_value = input_value + 10; else input_value = input_value + 15;
Computers and Technology
1 answer:
ICE Princess25 [194]3 years ago
6 0

Answer:

15

Explanation:

if ..else is the conditional statement which is used to check the condition is true or not, if the condition is true that execute the particular statement and if not it moves to else part for execution.

if condition is more than two we can use continuous if else statement

Syntax:

if(condition)

{

 statement;

}else if(condition)

{

  statement;

}else

{

 statement;

}

In the code:

The value of the input is 5.

first it goes to if part and check condition if 5 > 5, condition false it equal to 5 not greater than 5.

it then moves to else if part and check condition if 5 > 2, condition is true,

it execute the code inside the else if part. so, input_value become

5+10 which 15.

after that, program control terminate the if else statement it does not check further.

You might be interested in
Hisoka is creating a summary document for new employees about their options for different mobile devices. One part of his report
algol13

Hisoka would not include in his document that is Apple users file-based encryption to offer a higher level of security.

<h3>Does Apple use the file based encryption?</h3>

It is said that iOS and iPad OS devices are known to often use a file encryption system known to be Data Protection.

Therefore,  Hisoka would not include in his document that is Apple users file-based encryption to offer a higher level of security.

Hence option A is correct.

Learn more about encryption from

brainly.com/question/9979590

#SPJ1

3 0
2 years ago
A laptop computer is smaller than desktop computer. True or false
alina1380 [7]

Answer:

true

Explanation:

4 0
3 years ago
Read 2 more answers
Use semaphore(s) to solve the following problem. There are three processes: P1, P2, and P3. Each process Pi has a segment of cod
Lisa [10]

Answer:

See explaination

Explanation:

Here we will use two semaphore variables to satisfy our goal

We will initialize s1=1 and s2=1 globally and they are accessed by all 3 processes and use up and down operations in following way

Code:-

s1,s2=1

P1 P2 P3

P(s1)

P(s2)

C1

V(s2) .

P(s2). .

. C2

V(s1) .

P(s1)

. . C3

V(s2)

Explanation:-

The P(s1) stands for down operation for semaphore s1 and V(s1) stands for Up operation for semaphore s1.

The Down operation on s1=1 will make it s1=0 and our process will execute ,and down on s1=0 will block the process

The Up operation on s1=0 will unblock the process and on s1=1 will be normal execution of process

Now in the above code:

1)If C1 is executed first then it means down on s1,s2 will make it zero and up on s2 will make it 1, so in that case C3 cannot execute because P3 has down operation on s1 before C3 ,so C2 will execute by performing down on s2 and after that Up on s1 will be done by P2 and then C3 can execute

So our first condition gets satisfied

2)If C1 is not executed earlier means:-

a)If C2 is executed by performing down on S2 then s2=0,so definitely C3 will be executed because down(s2) in case of C1 will block the process P1 and after C3 execute Up operation on s2 ,C1 can execute because P1 gets unblocked .

b)If C3 is executed by performing down on s1 then s1=0 ,so definitely C2 will be executed now ,because down on s1 will block the process P1 and after that P2 will perform up on s1 ,so P1 gets unblocked

So C1 will be executed after C2 and C3 ,hence our 2nd condition satisfied.

4 0
3 years ago
In the airline industry, frequent flyer programs, ticket kiosks, and e-ticketing are all examples of capabilities that are _____
crimeas [40]

Answer:

valuable; rare

Explanation:

A valuable capability is that which gives a firm some competitive advantage. Core competencies are the operational activities that a company does best. A business’s core competencies are what distinguish it from other rival companies in its industry. While Rare capabilities are capabilities that a small amount of, if any, competitors possess. Those type of capabilities that are costly or impossible to imitate.

from the above explanation we can deduce that the modern technology implementation in the airline industry has made it possible to have valuable ptograms and softwares for carring out several task which are no longer scarce to procure.

7 0
3 years ago
Carskadon study on starting times for schools concluded that early school starting times cause________.
dimulka [17.4K]

Answer:

Early school starting times cause poor performance on tests, inattention in class, and drowsiness.

Explanation:

Carskadon study on early school starting time showed that it cause increased rate of rapid eye movement sleep in students and they doze off during lecture. Insufficient sleep lessens attentiveness levels in the class which affects students' potential to learn. The study showed that students do not perform well on tests. In addition to the difficulty in learning, there is an increased danger of accidents for those who drive to school due to dizziness.

3 0
3 years ago
Other questions:
  • The spreadsheet below shows the age, grade level, major, and minor of four students in college. A purple background in the Major
    7·1 answer
  • If you are feeling fatigued or sleepy while driving _________________.
    13·2 answers
  • Which of the following declares an abstract method in an abstract C++ class? (Points : 2) public: void print();
    14·1 answer
  • To create a chart, you need to select at least
    8·1 answer
  • Typing with capital letters and exclamation points in an e-mail is an example of
    12·2 answers
  • Engineers at Edison Laboratories developed a _____ strip that allowed them to capture sequences of images on film.
    14·2 answers
  • If you can name this you get 15 points: ↑↑↓↓←→←→βα
    10·1 answer
  • What are the names of different types of tablets<br>​
    13·1 answer
  • 1.erros can easily be ____ 2.work is done in an ____ no mess environment 3.colors do not _____ and brushes are never ______ 4.st
    14·1 answer
  • Assume that the Vehicle class contains a virtual method named CalculateMaxSpeed(). Assume that both the MotorVehicle and Automob
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!