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
AfilCa [17]
4 years ago
13

python Distance Traveled The distance a vehicle travels can be calculated as follows:Distance = Speed × Time For example, if a t

rain travels 40 miles per hour for three hours, the distance traveled is 120 miles. Design a program that asks the user for the speed of a vehicle (in miles per hour) and how many hours it has traveled. It should then use a loop to display the distance the vehicle has traveled for each hour of that time period. Here is an example of the output
Engineering
1 answer:
faust18 [17]4 years ago
3 0

Answer:

def show_travel(time,speed):

print("Hour\tDistance Travelled\n")

print("-----\t----------\n");

for i in range(1,time+1):

res=i*speed

print('%d\t\t%.1f'%(i,res))

def main():

speed=int(input("What is the speed of the vehicle in mph: "))

while speed <= 0:

print("speed must be greater than zero \n")

speed=int(input("What is the speed of the vehicle in mph: "))

time=int(input("How many hours has it traveled: "))

while time <= 0:

print("time must be greater than zero \n")

time=int(input("How many hours has it traveled: "))

show_travel(time,speed)

if __name__== "__main__":

main()

You might be interested in
What is a p-n junction? Show by the diagram.
Natalija [7]

Answer:

The p-n junction is a region formed when a p -type semiconductor material is joined to an n-type semiconductor material

Explanation:

The p type semiconductor has holes as its majority charge carriers making it positively charged while the n –types has an overall negative charge. At the junction the holes move towards the electron until such a time when there is a balance in charges from both materials, which leads to the formation of the depletion zone as shown in the attachment below

                           

5 0
4 years ago
During the recovery of a cold-worked material, which of the following statement(s) is (are) true?
Len [333]

Answer:

Some of the internal strain energy is relieved.

There is some reduction in the number of dislocations.

The electrical conductivity is recovered to its precold-worked state.

The thermal conductivity is recovered to its precold-worked state

Explanation:

The process of the recovery of a cold-worked material happens at a very low temperature, this process involves the movement and annihilation of points where there are defects, also there is the annihilation and change in position of dislocation points which leads to forming of the subgrains and the subgrains boundaries such as tilt, twist low angle boundaries.

4 0
3 years ago
The 10 foot wide circle quarter gate AB is articulated at A. Determine the contact force between the gate and the smooth surface
slamgirl [31]

Answer:

F = 641,771.52 \dfrac{lb-ft}{s^2}

Explanation:

Given that

R=8 ft

Width= 10 ft

We know that hydro statics force given as

  F=ρ g A X

ρ is the density of fluid

A projected area on vertical plane

X is distance of center mass of projected plane from free surface of water.

Here

X=8/2  ⇒X=4 ft

A=8 x 10=80  ft^2

So now putting the values

F=ρ g A X

F=62.4(32.14)(80)(4)

F = 641,771.52 \dfrac{lb-ft}{s^2}

   

4 0
4 years ago
Do the coil resistances have any effect on the plots?
PolarNik [594]
Because of the skin depth effect, the current at high frequency tends to flow at very low depth from radius. Then at high frequency the effective cross section of the wire is narrower than at DC.

Fro example skin depth at 100 kHz is 0.206 mm (0.008”), a wire more thicker than AWG26 could be a waste of copper, better use a bunch of thin wire (Litz wire) to rise the Q factor.
8 0
3 years ago
What are the searching algorithms used by search engines?
Juliette [100K]
Search engines use specific algorithms based on their data size and structure to produce a return value.
Linear Search Algorithm. ...
Binary Search Algorithm. ...
Relevancy. ...
Individual Factors. ...
Off-Page Factors.
6 0
3 years ago
Other questions:
  • Ayuda porfavor es para una tarea de mi capacitación de desarrollo microempresarial
    14·1 answer
  • A pitfall cited in Section 1.10 is expecting to improve the overall performance of a computer by improving only one aspect of th
    6·1 answer
  • You start your car and begin to pull out of a parking space. After leaving the space, You notice that the brake light on your in
    12·1 answer
  • How are scientific discoveries used in engineering design?
    12·1 answer
  • (a) The lattice constant of GaAs is 5.65 Å. Determine the number of Ga atoms andAs atoms per cm 3 .
    15·1 answer
  • What are the mechanical properties of a geotextile that are of most importance when using it as a separator in an unpaved road s
    12·1 answer
  • A two-phase mixture of water and steam with a quality of 0.63 and T = 300F expands isothermally until only saturated vapor rema
    7·1 answer
  • Cual es el costo del kwh
    8·1 answer
  • Calculate the percentage of recyclables in high socioeconomic localities.
    13·1 answer
  • It tells the amount of materials to be purchased.
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!