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
Elden [556K]
3 years ago
13

A dietician wants you to write a program that will calculate the number of calories a person can lose by walking at a slow pace

for a mile; however, the user will have only the distance given by a pedometer, which is measured in steps and not miles. Assume each mile a person walks is equivalent to 2000 steps, and that for every mile walked, a person loses 65 calories. Allow the user of the program to enter the number of steps taken throughout the day. The program will calculate the distance in miles and the number of calories lost. The user of the program should also be able to enter the day of the week the data is being calculated for. The day of the week, the distance in miles, and the calories lost should then be displayed to the screen.
How would I write the calculation for this problem in pseudocode?
Computers and Technology
1 answer:
gregori [183]3 years ago
6 0

Answer:

The pseudocode is as follows

1. Input Steps

2. Input Day

3. Miles = Steps/2000

4. Calories = 65 * Miles

5. Print Calories

6. Stop

Explanation:

This line gets the number of steps for the day

1. Input Steps

This line gets the current day

2. Input Day

The line calculates number of miles

3. Miles = Steps/2000

This line calculates the calories lost

4. Calories = 65 * Miles

This line prints the calories lost

5. Print Calories

The pseudocode ends here

6. Stop

You might be interested in
Do some Internet research on security vulnerabilities associated with SCADA and digital industrial control systems. Summarize th
Varvara68 [4.7K]

Answer:

Answer explained below

Explanation:

SCADA stands for Supervisor Control and Data Acquisition. It is Industrial control system that uses computers,network devices,graphical user interfaces and other devices such as PLC(Programmable logic controllers) for supervising and controlling industial processes located remotely.

Scada systems are being implemented on a large in various industrial sectors such as petrochemical industries,nuclear power plants,waste water treatment plants,pharmacuetical industries,food and beverage industries etc.

Scada uses various communication and network devices along with various hardware and software components to manage and control the real time processing of the industrial plants.

Although is a very reliable and robust system but its huge network and distributed nature makes it vulnerable to various cyber attacks. The cyber attacks on the Scada system can pose a threat to the industrial and the software environment along with the human race.Since Scada manages many major nuclear plants and petrochemical plants,if anyone hacks into the scada system of these plants it can cause a major threat to complete mankind.

The following are the factors that can cause vulnerabilities in the Scada systems:

The networking of the various enterprise control systems: The remote processing takes place because of the networking of the control systems of the various enterprises.A breach in the security of the enterprise will pose a threat to the working of the control systems.

Insecurity of the remote connections: Scada uses wireless and dial up modems for carrying put the remote activities.If the encryption standards are not followed properly then there can a threat to the information being transferred.

Use of Standard technologies:To ease the working around various platforms and remote locations,the industries have started using standard technologies which means that more number of people are well aware of these technologies and ways to hack them.

Public avalaibility of technical information: The technical information reagarding all the enterprises,their design plans are avalaible to the public on their websites which makes the whole system all the more vulnerable.

How To Avoid Vulnerabilities:

There are standards like ISA99(INdustrial Automation And Control System Security) that offer various strategies and procedures for implementing the security of industrial control systems.

There are government standards and guidelines like NERC-CIP(North American Electrical Reliability Corporation-Critical Infrastructure protection) standard.

Further the industries should good and efficient encryption and authentication techniques for remote communication.

7 0
3 years ago
Read first a user's given name followed by the user's age from standard input. Then use an ofstream object named outdata to writ
Stells [14]

Answer:

/*

* Program to write data to text file.

*/

#include<iostream>

#include<fstream>

#include<string.h>

using  namespace std;

int main()

{

//Variable to name and age of a person.

string name;

int age;

cout<<"Enter your name"<<endl;

cin>>name;

cout<<"Enter your age"<<endl;

cin>>age;

     //Creating object of ofstream.

   ofstream file;

   file.open ("outdata.txt");

   //Writing data to file named outdata.txt

   file<<name<<" "<<age;

   file.close();

 

}

Output:

Enter your name

John

Enter your age

25

Content of Output.txt:

John 25

Explanation:

To write data to a file  ofstream object is used. An ofstream object file is created first and then using this object a file named "outdata.txt" is created.

Finally using shift operator (<<), by means  of operator overloading, name and age of  person is transferred to file outdata.txt.

8 0
3 years ago
How do you know if you get a phone call that is a scam
Kamila [148]

It might have a really weird phone number, also if it sounds like its too good to be true it probably is. Good luck, and don't fall for scams!! XD

5 0
3 years ago
Read 2 more answers
Which of the following is a reason why the comments tool within PDF documents could be helpful? (Select all that apply.)
sveta [45]
You can use it to suggest edits for the document.

You can use it to make a note of clarification for someone else examining the document.

You can use it to cover up mistakes within the document.

That's what I think.
7 0
3 years ago
When programming, the word "execute" means which of these?
Inga [223]

Answer:

to run!

Explanation:

hope this is helpful!

7 0
3 years ago
Other questions:
  • Leslie’s form collected a huge amount of data. Over time the employees felt that the applications slowed down. What should lesli
    12·1 answer
  • Antivirus software installed to scan and monitor malware activities on a server or workstation would be identified as a ________
    8·1 answer
  • What technique can improve web search results? Add articles, prepositions, and pronouns Be general rather than specific Focus on
    10·1 answer
  • "Because Standard Error and Standard Ouput represent the results of a command and Standard Input represents the input required f
    6·1 answer
  • Choose two browsers and compare their security features.
    5·1 answer
  • You have just installed a new sound card in your system, and Windows says the card installed with no errors. When you plug up th
    5·1 answer
  • There are two main advantages to using multiple threads in a process: 1) Less work involved in creating a new thread rather than
    7·1 answer
  • What does 69 mean?<br> Whenever I watch memes they always talk about the number 69
    8·2 answers
  • Please help me on this please i am giving all of my points so please help me
    6·1 answer
  • (lesson 7.9: acceptance-rejection --- continuous examples.) consider the constant . on average, how many iterations (trials) wil
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!