0 votes
1 view
in Python by (240 points)
Hi all, as per the title I want to refer to the null object in Python. How do I go about doing this?

All help appreciated!

1 Answer

0 votes
by (51k points)

In Python there is no concept of null, instead, Python uses None. None tests that two variables refer to the same object. 

See the example below:-

>>> foo is None 


>>> foo = 'bar' 

>>> foo is None