-3

What is the type of the object that Python functions use, when a function does not return a "useful" object? For example:

from time import sleep
sleep(2)
Matthias
  • 12,873
  • 6
  • 42
  • 48
  • 4
    Does this answer your question? [return, return None, and no return at all?](https://stackoverflow.com/questions/15300550/return-return-none-and-no-return-at-all) – Yonlif Jul 09 '20 at 11:53

1 Answers1

1

Missing return statement is the same as returning None

>>> sleep(2) is None
True
Michael Bianconi
  • 5,072
  • 1
  • 10
  • 25
  • thanks michael for yr time but i just want to know the answer for,What is the type of the object that Python functions use, when a function does not return a "useful" object? – Najeem Fazil Jul 09 '20 at 11:55
  • 1
    @NajeemFazil the type of `None` is `NoneType`. – mkrieger1 Jul 09 '20 at 11:56