if you really want golf you can do this which also works in 2.4:
`steam = (sys.stderr, sys.stdout)[stdout is True]`
But it loses readability....