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
Dimas [21]
3 years ago
14

A pedometer treats walking 2,000 steps as walking 1 mile. Write a program whose input is the number of steps, and whose output i

s the miles walked. Output each floating-point value with two digits after the decimal point, which can be achieved as follows: print('{:.2f}'.format(your_value)) Ex: If the input is: 5345 the output is: 2.67 Your program must define and call the following function. The function should return the amount of miles walked. def steps_to_miles(user_steps)
Computers and Technology
1 answer:
Oksi-84 [34.3K]3 years ago
3 0

Answer:

Follows are the code to the given question:

def steps_to_miles(user_steps):#defining a method steps_to_miles that takes a variable user_steps

   return user_steps/2000#use return to calculate the steps

user_steps = int(input())#defining a variable user_steps that holds value from the user-end

print('%0.2f' % steps_to_miles(user_steps))#defining print that calls the steps_to_miles method

Output:

5345

2.67

Explanation:

In this code a method "steps_to_miles" that takes "user_steps" in the parameter inside the method a return keyword is used that calculates the user steps and return its values.

Outside the method, a "user_steps" variable is declared that inputs the value from the user-end pass into the method and prints its value.

You might be interested in
460N of force is exerted on an object with a surface area of 2,5m.How much pressure is felt by the object?​
BartSMP [9]

Explanation:

p=F/A

p=460N/2m×5m

=46N/m2

7 0
2 years ago
Read 2 more answers
How to make the heart symbol in photoshop
sveta [45]
Click the font drop-down box in the tool settings bar. Select "Arial." 6. Press "Alt-3" using your keyboard number pad's "3" key to insert the heart symbol<span>.</span>
3 0
3 years ago
Read 2 more answers
You need to set up a network that needs to span multibple buildings. For this reason, you want to use the cabling that supports
prisoha [69]

Answer:

Extended star topology

Explanation:

The Extended star topology also known as the tree topology comprises of characteristics of the linear bus topology and star topology.

It consist of multiple star connected topologies connected to a linear backbone bus topology. It has a wider communication area than the star topology and uses more cabling length. All the star networks are connected to a central connection which allows to have a full functioning network when others fails.

5 0
3 years ago
What command displays detail information about the OSPF interfaces, including the authentication method?
statuscvo [17]
<span>The answer is Show IP OSPF interface

Hope this helped :)</span>
8 0
3 years ago
Read 2 more answers
A _____ is a character or group of characters that has a specific meaning. a. field b. record c. file d. database
zubka84 [21]

A character or collection of characters with a specific meaning is called a field.

<h3>What does the technical term "field" mean?</h3>

A field is a purpose-driven, typically fixed-sized section in a fixed or known location within a unit of data, such as a record, message header, or computer instruction. A field may be divided into smaller fields depending on the situation.

<h3>What does a file structure field mean?</h3>

A record is an entire set of fields, a field is a single piece of information, and a file is a collection of records. An analogy between a file and a phone book is a phone book. There is a list of records in it, and each record has three fields: a name, an address, and a phone number.

learn more about field here  

<u>brainly.com/question/28002617</u>

#SPJ4

8 0
1 year ago
Other questions:
  • Managing your calendar and emails can be easily accomplished through ___ software
    8·1 answer
  • This is in government
    15·1 answer
  • What emphasizes extensive user involvement in the rapid and evolutionary construction of working prototypes of a system to accel
    15·1 answer
  • Imagine that you have access to a class named MyCircle that has void setRadius(double r) and double getRadius() methods. Write a
    14·1 answer
  • What is a multipurpose network device?
    10·1 answer
  • You are configuring two PCs for your network, PC-A is given an IP address of 192.168.1.18 and PC-B is given an IP address of 192
    15·1 answer
  • Help fast plzzzzzzzzzzzz ​
    10·2 answers
  • Please Helpppp Me User Interface Design ensures that the interface has elements that are easy to ________________. (Choose all t
    8·1 answer
  • What software application is most appropriate to use to create multimedia presentations?
    6·2 answers
  • Which describes the Paradox of Automation?
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!