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
faust18 [17]
3 years ago
13

Write a program that reads a floating-point number from the user and prints "zero", "positive" or "negative"

Computers and Technology
1 answer:
Lorico [155]3 years ago
3 0
```
#!/usr/local/bin/python3

foo = float( input( "Enter a number: " ) )
if( foo < 0.0 ):
    print( "negative" )
elif( foo > 0.0 ):
    print( "positive" )
else
    print( "zero" )

exit( 0 )
```

You might be interested in
3.A ball is thrown into the air with an initial velocity of 15 m/s. a.How long does it take the ball to reach maximum height?b.W
ehidna [41]

Answer:  a) = 1.5 sec.  b= 11.5 m. c=0  d= 1.5 sec.

Explanation:

a) Once thrown into the air , the only influence on the ball is gravity, so, we can conclude that the acceleration acting on the ball is the one due to gravity, i.e., g= 9.8 m/sec².

Applying the definition of acceleration, we can write the following equation:

a= (vf-vo) / t   ⇒ g = vf-vo / t. (1)

Now, when the ball reaches to his maximum height, it stops momentarily, and then starts to fall, so for this height, we can write vf=0.

Replacing  in (1), and solving for t, we get:

t = (0 -vo) / g = -15 m/s/ - 9.8 m/sec² (Taking upward as positive  direction)

a) t= 1.5 sec.

Replacing this value in the kinematic equation for displacement, when vo=15 m/s, we get:

hmax: 15 m/sec . 1.5 sec -1/2. 9.8 m/sec². (1.5 sec) ² (2)

b) hmax= 11.5 m

c) vf= 0 (as explained above)

Finally, in order to know how long the ball takes to return to its initial height, we know that for the falling part of the trajectory, vo=0, so we can write the equation for displacement as follows:

h=-hmax (because it returns to the same starting point)= 1/2 gt²=-11.5 m

Solving for t, we get:

d) t=1.5 sec.

It can be seen that the time used in going up, it is the same for going down, to travel the same distance.

This result is completely general and applies to any free fall problem.

3 0
3 years ago
Which tool could be used to display only rows containing presidents who served two terms?
kherson [118]

Answer: The tool that could be used to display only the rows containing the presidents who served two terms is the<u> Filter.</u>

Explanation:

If you are using Excel the filter tool is a great way to find the relevant information you are searching for. This will remove all other data from the search results, in this case presidents that only served one term.

The filtering of rows can be used three ways;

  • By the value
  • By the criteria
  • By the format

By using the filter, you can find any phrase, number, dates, etc. Multiple columns can be filtered at the same time. Also, blank cells can be filtered out.

5 0
3 years ago
Read 2 more answers
Marty uses a customized database to sort parts and track inventory. The customized database is an example of _____.
Alexeev081 [22]

cataloging is a term for that

5 0
3 years ago
Describe the difference between a chained conditional and a nested conditional. Give your own example of each.
I am Lyosha [343]
Here you go :) have a good day :))))

5 0
3 years ago
Does two core processors mean that it is twice as fast do you agree? why?
vlabodo [156]

Answer:

the friendships the following link and fill out our related information

Explanation:

consisting of a new one of the cell number of people who want

3 0
3 years ago
Other questions:
  • Which of these is a weakness of written communication?
    8·1 answer
  • In the windows firewall, any rules preceded by a __________ checkmark have not been enabled. black gray green red
    13·1 answer
  • How is a recession determined?
    10·1 answer
  • Which of the following is a common financial aid scam that students sometimes find on the Internet? Grant and scholarship databa
    8·2 answers
  • A barcode is a Select one: a. coded instruction needed to control computer hardware. b. confidential computer code required by H
    7·1 answer
  • Suppose you own a travel agency in a large city. You have many corporate clients, but growth has slowed somewhat Some long-term
    15·1 answer
  • If I want to add a new slide to my presentation, which option would I click on?
    5·1 answer
  • 4. In paragraph 7, what is the meaning of the phrase "not
    13·1 answer
  • What is Data rate?<br> What is BAUD RATE?<br> What is bandwidth?
    8·1 answer
  • which term describes the layer of software that resides between the virtual operating system and the physical hardware it runs o
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!