Use list as a stack : Stack : Data Structure PYTHON examples


PYTHON examples » Data Structure » Stack »

 

Use list as a stack


Use list as a stack: push onto stack

L = []
L.append(1)                    # push onto stack
L.append(2)
print L


           
       



    Related Scripts with Example Source Code in same category :

Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON examples

 Navioo Data Structure
» Stack