-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
44 lines (36 loc) · 1019 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
lista = list();
option = 5;
def menu():
print("Digite uma opção:");
print(" 1- Adicionar");
print(" 2- Alterar");
print(" 3- Excluir");
print(" 4- Consultar");
print(" 0- Sair");
option = input();
def inserir():
print("Digite o Produto:");
produto = input();
lista.insert(len(lista), produto);
os.system('cls' if os.name == 'nt' else 'clear');
def main():
menu();
while(option != 0):
if option == 1 :
os.system('cls' if os.name == 'nt' else 'clear');
insert();
elif option == 2:
os.system('cls' if os.name == 'nt' else 'clear');
insert();
elif option == 3:
os.system('cls' if os.name == 'nt' else 'clear');
insert();
elif option == 4:
os.system('cls' if os.name == 'nt' else 'clear');
insert();
exit();
if __name__ == "__main__":
main();