For example, how could I condense
In [1]: for x in xrange(1,11):
...:     if x%2==0:
...:         print x
into one line?
Edit: Thanks guys! That was exactly what I was looking for. To make this a little more challenging though, is there a way to add elif & else and still have it be on one line?
To use the previous example,
for x in xrange(1,11):
   if x%2==0:
      print x
   else
      print "odd"
 
     
     
     
     
    