This is a simple program that opens programs from a simple spot:import randomimport webbrowserimport osimport yagmail#importing all module ^^greetings = ['hola', 'hello', 'hi', 'Hi', 'hey!','hey']random_greeting = random.choice(greetings)maps = ['maps', 'open google maps', 'open maps', 'please open google maps']google = ['google', 'open google', 'please open google']mail = ['mail', 'open mail', 'open google mail', 'please open google mail', 'gmail', 'open gmail', 'please open gmail']safari = ['safari', 'open safari', 'please open safari']calc = ['calc', 'calculator', 'open calc', 'open calculator', 'please open calc', 'please open calculator']dict = ['dict', 'dictionary', 'open dict', 'open dictionary', 'please open dict', 'please open dictionary']cal = ['cal', 'calendar', 'open cal', 'open calendar']con = ['contacts', 'con', 'open contacts']dash = ['dash', 'dashboard', 'open dashboard', 'open dash']chess = ['chess', 'play chess', 'open chess']face = ['facetime', 'face', 'open facetime']band = ['garageband', 'garage band', 'band', 'garage', 'open band', 'open garage', 'open garage band', 'open garageband']movie = ['imovie', 'open imovie']ibooks = ['ibooks', 'open ibooks']itunes = ['itunes', 'open itunes']kindle = ['kindle', 'open kindle']launch = ['launchpad', 'open launchpad']amail = ['email', 'open email']messages = ['messages', 'open messages']notes = ['notes', 'open notes']photos = ['photos', 'open photos']reminders = ['reminders', 'open reminders']stickies = ['stickies', 'open stickies']textwrangler = ['textwrangler', 'text wrangler', 'open textwrangler', 'open text wrangler']textedit = ['textedit', 'text edit', 'text', 'open text edit', 'open textedit']xcode = ['xcode', 'open xcode']emailing = ['send email', 'send']question = ['How are you?','How are you doing?']responses = ['Okay, How are you?',I'm fine, How are you?]random_response = random.choice(responses)#Defining everything ^^while True:    userInput = raw_input(>>> ).lower()    if userInput in greetings:        print(random_greeting)    elif userInput in question:        print(random_response)    elif userInput == 'help':        print('-------------------------------------------\nThis Program was created by Ethan Lee\nIf you need a list of Directories, Enter directories.\n-------------------------------------------')    elif userInput == 'directories':        print(Enter the Program name to go to the program.\nPrograms:\n'Maps'\n'Google'\n'Safari'\n'Calculator'\n'Dictionary'\n'Calendar'\n'Contacts'\n'Chess'\n'Dashboard'\n'FaceTime'\n'GarageBand'\n'iBooks'\n'iMovie'\n'iTunes'\n'Kindle'\n'Launchpad'\n'Mail'\n'Messages'\n'Notes'\n'Photos'\n'Reminders'\n'Stickies'\n'TextEdit'\n'TextWrangler'\n'Xcode')    elif userInput in maps:        webbrowser.open('https://www.google.com/maps/')    elif userInput in google:        webbrowser.open('https://www.google.com')elif userInput in mail:    webbrowser.open('https://mail.google.com')elif userInput in safari:    os.system(open /Applications/Safari.app)elif userInput in calc:    os.system(open /Applications/Calculator.app)elif userInput in dict:    os.system(open /Applications/Dictionary.app)elif userInput in cal:    os.system(open /Applications/Calendar.app)elif userInput in con:    os.system(open /Applications/Contacts.app)elif userInput in dash:    os.system(open /Applications/Dashboard.app)elif userInput in chess:    os.system(open /Applications/Chess.app)elif userInput in face:    os.system(open /Applications/FaceTime.app)elif userInput in band:    os.system(open /Applications/GarageBand.app)elif userInput in movie:    os.system(open /Applications/iMovie.app)elif userInput in ibooks:    os.system(open /Applications/iBooks.app)elif userInput in itunes:    os.system(open /Applications/iTunes.app)elif userInput in kindle:    os.system(open /Applications/Kindle.app)elif userInput in launch:    os.system(open /Applications/Launchpad.app)elif userInput in amail:    os.system(open /Applications/Mail.app)elif userInput in con:    os.system(open /Applications/Contacts.app)elif userInput in messages:    os.system(open /Applications/Messages.app)elif userInput in notes:    os.system(open /Applications/Notes.app)elif userInput in photos:    os.system(open /Applications/Photos.app)elif userInput in reminders:    os.system(open /Applications/Reminders.app)elif userInput in stickies:    os.system(open /Applications/Stickies.app)elif userInput in textwrangler:    os.system(open /Applications/TextWrangler.app)elif userInput in textedit:    os.system(open /Applications/TextEdit.app)elif userInput in xcode:    os.system(open /Applications/Xcode.app)elif userInput in emailing:    emailh = raw_input('Your email: ')    email = raw_input('Send to: ')    subject = raw_input('Subject: ')    body = raw_input('Body: ')    yagmail.SMTP(emailh).send(email, subject, body)    print('Email Sent.')    file = open(email.txt, a);    file.write('Through\n')    file.close()else:    print(I did not understand what you said\nEnter 'help' if you need help.\nEnter 'directories' if you need directories.)(Actual process of opening and running commands)
Opening programs from a simple spot
python;beginner;osx