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
Mrac [35]
3 years ago
13

Decide what activity is most appropriate based on the temperature. If the temperature is greater than 80 degrees, then display t

he message "Go swimming." If the temperature is between 60 and 80 degrees, display the message "Go biking". If the temperature is less than 60 degrees, display the message "Go for a walk". The input will be the temperature.

Computers and Technology
1 answer:
Ede4ka [16]3 years ago
6 0

Answer:

Here is the C++ program:

#include <iostream> //to use input output functions

using namespace std; //to access objects like cin cout

int main(){// start of main function

   int temp; //declare a variable to store value for temperature

   cout<<"Enter temperature: "; //prompts user to enter temperature

   cin>>temp; //reads value of temp from user

   if(temp>80) //if temperature is greater than 80 degrees

     { cout<<"Go swimming";    } //displays Go swimming

   else if(temp<=80&&temp>=60) //if temperature is between 60 and 80

         {   cout<<"Go biking";    } //displays Go biking

   else //if temperature is less than 60 degress

   cout<<"Go for a walk"; } //displays Go for a walk

Explanation:

The program prompts the user to enter value of temperature. It stores the value of temperature in temp variable. Then the first if condition checks if the value of temp is greater than 80. If it evaluates to true, then the print statement inside the body of this if statement executes which is "Go swimming". If this condition evaluates to false then program moves to the else if condition which checks if the value of temp is between 60 and 80. There is a logical operator AND (&&) is used between both expressions to check temperature between two ranges. If it evaluates to true, then the print statement inside the body of this if statement executes which is "Go biking". If this condition evaluates to false then program moves to the else part which has a print statement that displays "Go for a walk" on output screen. The screenshot of program along with its output is attached.

You might be interested in
In this era of technology, everyone uses emails for mail and messages. Assume you have also used the
ipn [44]

Answer:

A class may be a structured diagram that describes the structure of the system.  

It consists of sophistication name, attributes, methods, and responsibilities.  

A mailbox and an email message have certain attributes like, compose, reply, draft, inbox, etc.

Software architecture affects:

Performance, Robustness, Distributability, Maintainability.  

Explanation:

See attachment for the Model object classes which may be utilized in the system implementation to represent a mailbox and an email message.

Advantages:

Large-scale reuse Software architecture is vital because it affects the performance, robustness, distributability, and maintainability of a system.

Individual components implement the functional system requirements, but the dominant influence on the non-functional system characteristics is that the system's architecture.

Three advantages of System architecture:

• Stakeholder communication: The architecture may be a high-level presentation of the system which will be used as attention for discussion by a variety of various stakeholders.

• System analysis: making the system architecture explicit at an early stage within the system development requires some analysis.

• Large-scale reuse:

An architectural model may be a compact, manageable description of how a system is organized and the way the components interoperate.

The system architecture is usually an equivalent for systems with similar requirements then can support large-scale software reuse..

7 0
3 years ago
Define a function in Scheme (or relation in Prolog) that checks whether a set of elements (represented as a list) is a subset of
mafiozo [28]

Answer:

subset([],[]).

       subset([X|L],[X|S]) :-

           subset(L,S).

       subset(L, [_|S]) :-

           subset(L,S).

Success:

     subset([1,3], [1,2,3]).

     subset(X, [1,3,4]).        % error handling to compare sets in a given order

Fail:

     subset([2,1], [1,2,3]).   % compares in a different order from the first.

Explanation:

The function "Subset" in the source code above accepts two sets, then checks if the first set is a subset of the second. The code returns true if the condition is met.

4 0
3 years ago
ANSWERS FOR PLATO!!!
Anastaziya [24]

The thing which the second element in a pair of HTML tags contain is "/" and is known as the Closing Tag.

<h3>What is an HTML Tag?</h3>

This refers to the keywords that are used in the building block of a website to indicate how a web browser would interpret and display the content.

Hence, we can see that in HTML tags, there are always the Opening and Closing Tags that are used to enclose lines of code and when paired together are known as container tags.

Read more about HTML elements here:

brainly.com/question/9069928

#SPJ1

6 0
2 years ago
How do you know that the computer is infected by virus​
Olegator [25]
  1. Slow computer performance (taking a long time to start up or open programs)
  2. Problems shutting down or restarting.
  3. Missing files.
  4. Frequent system crashes and/or error messages.
  5. Unexpected pop-up windows.
6 0
2 years ago
Shortest Remaining Time First is the best preemptive scheduling algorithm that can be implemented in an Operating System.
Ierofanga [76]

Answer:

a

Explanation:

Yes, true.

Shortest Remaining Time First, also popularly referred to by the acronym SRTF, is a type of scheduling algorithm, used in operating systems. Other times it's not called by its name nor its acronym, it is called the preemptive version of SJF scheduling algorithm. The SJF scheduling algorithm is another type of scheduling algorithm.

The Shortest Remaining Time First has been touted by many to be faster than the SJF

7 0
3 years ago
Other questions:
  • 3 applications of cumulative probability distribution in medical field?​
    9·1 answer
  • How do you site this page??
    12·1 answer
  • The letters LAN stand for Area Network.
    9·2 answers
  • ? I don’t understand
    8·2 answers
  • Wrtie a program in which we will pass a value N. N can be positive or negative. If N is positive then output all values from N d
    8·1 answer
  • If you have 128 oranges all the same size, color, and weight except one orange is heavier than the rest. Write down a C++ Code/A
    7·1 answer
  • Which kind of image is indispensable and needs added text to go with it?
    13·1 answer
  • Suppose that we want to enhance the processor used for Web serving. The new processor is 10 times faster on computation in the W
    6·1 answer
  • Is a system software that manages the hardware resources and provides services 5o the application software
    6·1 answer
  • which one of the following would not normally be found in an organization's information security policy?
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!