Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
what module is NoneType in?
#11
for testing i can just do:
    if foo is None:
        break
but i want to know which module will correctly define NoneType. or do i need to do:
NoneType = type(None)
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply
#12
The answer is that you need to do NoneType = type(None) if you want a variable name for this type.
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020