lists, uppercase?

Bjorn Pettersen BPettersen at NAREX.com
Wed Jan 30 22:54:29 CET 2002


> From: maximilianscherr [mailto:MaximilianScherr at T-Online.de] 
> 
> just two questions this time:
> 
> how can i change a list like this
> [1, 2, 3, 4]
> to
> [4, 3, 2, 1]

x = [1, 2, 3, 4]
x.reverse()

> how can i get to know if a string is totally uppercase?

if myString == myString.upper():
    # it's all upper case

> thanks in advance,
> 
> Max

-- bjorn




More information about the Python-list mailing list