Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- # -*- coding: UTF-8 -*-
- __author__ = 'Julio Tentor <jtentor@fi.unju.edu.ar>'
- from StackList import Stack
- print("Demo de Stack en Python")
- miPila = Stack(5)
- miPila.Push('a')
- miPila.Push("Hola que tal")
- miPila.Push(8956)
- while (not miPila.Empty):
- print(miPila.Pop())
- try:
- print(miPila.Pop())
- except ValueError as err:
- for a in err.args:
- print(a)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement