A = X > Y ? X : Y
Brad Howes
bradh at mediaone.net
Tue Feb 8 20:23:28 EST 2000
More information about the Python-list mailing list
Tue Feb 8 20:23:28 EST 2000
- Previous message (by thread): A = X > Y ? X : Y
- Next message (by thread): A = X > Y ? X : Y
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Curtis Jensen <cjensen at be-research.ucsd.edu> writes: > I fear that this question has already been asked, but is there and > equivalant one line command that is equivalant to the C command: > > a = x > y ? x : y Its in the FAQ -- and its not as pretty: a = ( ( x > y ) and x ) or y Seems to work fine for numbers -- not sure about objects or strings. Brad -- "Were people this stupid before TV?" -- _White Noise_ by Don DeLillo
- Previous message (by thread): A = X > Y ? X : Y
- Next message (by thread): A = X > Y ? X : Y
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list