Discuss 'and' does not work as I thought in the Python Programming forum on Dev Shed. 'and' does not work as I thought Python Programming forum discussing coding techniques, tips and tricks, and Zope related information. Python was designed from the ground up to be a completely object-oriented programming language.
Time spent in forums: 13 h 14 m 44 sec
Reputation Power: 0
space1 = 'X'
space2 = 'O'
space3 = 'X'
if space1 == 'X' and space2 == 'X' and space3 == 'X':
print 'space1 and space2 and space3 all equal X'
else: print 'space1 and space2 and space3 do not all equal X'
Ok this works. Thanks for putting it into perspective for me.