John Salerno wrote: > I'm a little confused. Why doesn't s evaluate to True in the first part, > but it does in the second? Is the first statement something different? > > >>> s = 'hello' > >>> s == True > False > >>> if s: > print 'hi'
"true" != "True". comparing a value to another value isn't the same thing as interpreting a value in a specific context: http://docs.python.org/lib/truth.html </F> -- http://mail.python.org/mailman/listinfo/python-list