def main():
    print('Available Options: C=Create, R=Read, U=Update, D=Delete ')
    choice = input('Choose your option = ')

    if choice == 'C':
        createObj=Create()
        createObj.func_CreateData()
    elif choice == 'R':
        readObj =  Read()
        readObj.func_ReadData()
    elif choice == 'U':
        updateObj = Update()
        updateObj.func_UpdateData()
    elif choice == 'D':
        deleteObj = Delete()
        deleteObj.func_DeleteData()
    else:
        print('Wrong choice, You are going exist.')
Ejemplo n.º 2
0
def main():
    while 1:
        print(
            'Available Options: C=Create, R=Read, U=Update, D=Delete, E=Exit ')
        choice = input('Choose your option = ')

        if choice == 'C':
            createObj = Create()
            createObj.func_CreateData()
        elif choice == 'R':
            readObj = Read()
            readObj.func_ReadData()
        elif choice == 'U':
            updateObj = Update()
            updateObj.func_UpdateData()
        elif choice == 'D':
            deleteObj = Delete()
            deleteObj.func_DeleteData()
        elif choice == 'E':
            break