Guest User

Untitled

a guest
Dec 10th, 2018
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. #-*- coding:utf-8 -*-
  2. class tienda():
  3.  
  4. def __init__(self):
  5. self.productos = int(raw_input('cantidad de stock de compra?: '))
  6. def entrada(self,stock):
  7. self.productos += stock
  8. def salida(self,stock):
  9. self.productos -= stock
  10. def contador(self):
  11. return self.productos
  12.  
  13. producto = tienda()
  14. print producto.contador()
  15.  
  16. producto.salida(int(raw_input('CANTIDAD DE PRODUCTOS VENDIDOS?: ')))
  17. print 'TE QUEDAN', producto.contador()
Add Comment
Please, Sign In to add comment