()
| 53 | } |
| 54 | #----------------------------------------main()-------------------------------------- |
| 55 | def main(): |
| 56 | print(responses[0],responses[1],sep='\n') |
| 57 | while True: |
| 58 | print() |
| 59 | text=input("Enter some text: ") |
| 60 | for word in text.split(' '): |
| 61 | if word.upper() in operations.keys(): |
| 62 | try: |
| 63 | l=extract_numbers_from_text(text) |
| 64 | r=operations[word.upper()](l[0],l[1]) |
| 65 | print(r) |
| 66 | except: |
| 67 | print("Something is wrong,Please retry !!!") |
| 68 | finally: |
| 69 | break |
| 70 | |
| 71 | elif word.upper() in commands.keys(): |
| 72 | commands[word.upper()]() |
| 73 | break |
| 74 | else: |
| 75 | sorry() |
| 76 | if __name__=="__main__": |
| 77 | main() |
| 78 |
no test coverage detected