Back to index

plone3  3.1.7
reverseList.py
Go to the documentation of this file.
00001 ## Script (Python) "reverseList.py $Revision: 5948 $"
00002 ##bind container=container
00003 ##bind context=context
00004 ##bind namespace=
00005 ##bind script=script
00006 ##bind subpath=traverse_subpath
00007 ##parameters=aList
00008 ##title=Reverse A List or Tuple and Return it
00009 ##
00010 
00011 myList=[]
00012 
00013 try:
00014     myList=list(aList)[:]
00015     myList.reverse()
00016 except TypeError:
00017     pass
00018 
00019 return myList