├── Acronyms Generator └── Acronyms Generator.py ├── Alarm Clock ├── Alarm Clock.py └── alarm.wav ├── BMI Calculator └── BMI Calculator.py ├── Color Text Printer └── Color Text Printer.py ├── Dice Roller └── Dice Roller.py ├── Echo Chatbot └── Echo Chatbot.py ├── Email Slicer └── Email Slicer.py ├── Fahrenheit to Celsius Converter └── Fahrenheit to Celsius Converter.py ├── Guess the number (computer) └── guessthenumber_computer.py ├── Guess the number (user) └── guess thenumber_user.py ├── Hangman ├── hangman.py └── words.py ├── Madlibs └── madlib.py ├── Password Generator └── Password Generator.py ├── QR code generator └── QR code generator.py ├── Quiz Game ├── Quiz Game.py └── questions.py ├── Rock Paper Scissors └── rockpaperscissors.py └── Story Generator └── Story Generator.py /Acronyms Generator/Acronyms Generator.py: -------------------------------------------------------------------------------- 1 | # Taking user input 2 | user_input = input("Enter a phrase: ") 3 | 4 | # Getting rid of 'of' word using replace() method & Spiliting the user input into individual words using split() method 5 | phrase = (user_input.replace('of', '')).split() 6 | 7 | # Initializing an empty string to append the acronym 8 | a = "" 9 | 10 | # for loop to append acronym 11 | for word in phrase: 12 | a = a + word[0].upper() 13 | 14 | print(f'Acronym of {user_input} is {a}') -------------------------------------------------------------------------------- /Alarm Clock/Alarm Clock.py: -------------------------------------------------------------------------------- 1 | # Importing required libraries 2 | from datetime import datetime #To set date and time 3 | from playsound import playsound #To play sound 4 | 5 | def validate_time(alarm_time): 6 | if len(alarm_time) != 11: 7 | return "Invalid time format! Please try again..." 8 | else: 9 | if int(alarm_time[0:2]) > 12: 10 | return "Invalid HOUR format! Please try again..." 11 | elif int(alarm_time[3:5]) > 59: 12 | return "Invalid MINUTE format! Please try again..." 13 | elif int(alarm_time[6:8]) > 59: 14 | return "Invalid SECOND format! Please try again..." 15 | else: 16 | return "ok" 17 | 18 | while True: 19 | alarm_time = input("Enter time in 'HH:MM:SS AM/PM' format: ") 20 | 21 | validate = validate_time(alarm_time.lower()) 22 | if validate != "ok": 23 | print(validate) 24 | else: 25 | print(f"Setting alarm for {alarm_time}...") 26 | break 27 | 28 | alarm_hour = alarm_time[0:2] 29 | alarm_min = alarm_time[3:5] 30 | alarm_sec = alarm_time[6:8] 31 | alarm_period = alarm_time[9:].upper() 32 | 33 | while True: 34 | now = datetime.now() 35 | 36 | current_hour = now.strftime("%I") 37 | current_min = now.strftime("%M") 38 | current_sec = now.strftime("%S") 39 | current_period = now.strftime("%p") 40 | 41 | if alarm_period == current_period: 42 | if alarm_hour == current_hour: 43 | if alarm_min == current_min: 44 | if alarm_sec == current_sec: 45 | print("Wake Up!") 46 | playsound('D:/Library/Documents/Projects/Coding/Beginner Python Projects/Alarm Clock/alarm.wav') 47 | break 48 | -------------------------------------------------------------------------------- /Alarm Clock/alarm.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mindninjaX/Python-Projects-for-Beginners/3cf3bbd318f47ddb09eca21a22a721f9b68f80f7/Alarm Clock/alarm.wav -------------------------------------------------------------------------------- /BMI Calculator/BMI Calculator.py: -------------------------------------------------------------------------------- 1 | height = float(input("Enter your height in cm: ")) 2 | weight = float(input("Enter your weight in kg: ")) 3 | 4 | BMI = weight / (height/100)**2 5 | 6 | print(f"You BMI is {BMI}") 7 | 8 | if BMI <= 18.4: 9 | print("You are underweight.") 10 | elif BMI <= 24.9: 11 | print("You are healthy.") 12 | elif BMI <= 29.9: 13 | print("You are over weight.") 14 | elif BMI <= 34.9: 15 | print("You are severely over weight.") 16 | elif BMI <= 39.9: 17 | print("You are obese.") 18 | else: 19 | print("You are severely obese.") -------------------------------------------------------------------------------- /Color Text Printer/Color Text Printer.py: -------------------------------------------------------------------------------- 1 | import colorama 2 | # Back for background, Fore for text color 3 | from colorama import Back, Fore 4 | 5 | # This line is make sure that the color style resets once the execution of program is complete 6 | colorama.init(autoreset = True) 7 | 8 | text = input("Enter a pharse or sentence: ") 9 | 10 | # Colorama has limited color options 11 | print(Fore.BLACK + Back.WHITE + text) 12 | print(Fore.RED + Back.CYAN + text) 13 | print(Fore.GREEN + Back.MAGENTA + text) 14 | print(Fore.YELLOW + Back.BLUE + text) 15 | print(Fore.BLUE + Back.YELLOW + text) 16 | print(Fore.MAGENTA + Back.GREEN + text) 17 | print(Fore.CYAN + Back.RED + text) 18 | print(Fore.WHITE + Back.BLACK + text) 19 | -------------------------------------------------------------------------------- /Dice Roller/Dice Roller.py: -------------------------------------------------------------------------------- 1 | # Importing randome module 2 | import random 3 | 4 | # Initiating an while loop to keep the program executing 5 | while True: 6 | print("Rolling Dice...") 7 | 8 | # Using random.randint(1,6) to generate a random value between 1 & 6 9 | print(f"The value is ", random.randint(1,6)) 10 | 11 | # Asking user to roll the dice again or quit 12 | repeat = input("Roll Dice again? 'y' for yes & 'n' for no: ") 13 | 14 | # If the user answers negative the loop will break and program execution stops otherwise the program will continue executing 15 | if repeat == 'n': 16 | break -------------------------------------------------------------------------------- /Echo Chatbot/Echo Chatbot.py: -------------------------------------------------------------------------------- 1 | print("Let's talk! Enter 'quit' to exit...") 2 | 3 | while True: 4 | user = input("You: ") 5 | print(f"Bot: {user}") 6 | 7 | if user == 'quit': 8 | break -------------------------------------------------------------------------------- /Email Slicer/Email Slicer.py: -------------------------------------------------------------------------------- 1 | email = input("Enter Your Email: ").strip() 2 | 3 | username = email[:email.index('@')] 4 | domain = email[email.index('@') + 1:] 5 | 6 | print(f"Your username is {username} & domain is {domain}") -------------------------------------------------------------------------------- /Fahrenheit to Celsius Converter/Fahrenheit to Celsius Converter.py: -------------------------------------------------------------------------------- 1 | temp = float(input("Enter temperature in Fahrenheit: ")) 2 | 3 | celsius = (temp - 32) * 5/9 4 | 5 | print(f"{temp} in Fahrenheit is equal to {celsius} in Celsius") -------------------------------------------------------------------------------- /Guess the number (computer)/guessthenumber_computer.py: -------------------------------------------------------------------------------- 1 | import random 2 | 3 | max_num = 30 4 | 5 | random_number = random.randint(1, max_num) 6 | guess = 0 7 | while guess != random_number: 8 | guess = int(input(f"Guess the number between 1 & {max_num}: ")) 9 | if guess < random_number: 10 | print("Wrong! Too low...") 11 | elif guess > random_number: 12 | print("Wrong! Too high...") 13 | print(f"Thats Right! Random number is {random_number}") -------------------------------------------------------------------------------- /Guess the number (user)/guess thenumber_user.py: -------------------------------------------------------------------------------- 1 | import random 2 | 3 | def guess(num): 4 | low = 1 5 | high = num 6 | feedback = '' 7 | while feedback != 'c': 8 | if low != high: 9 | guess = random.randint(low, high) 10 | else: 11 | guess = low 12 | # guess = random.randint(low, high) 13 | feedback = input(f"Is it {guess}? Is it too low (L), too high (H) or its just correct (C)?").lower() 14 | if feedback == 'l': 15 | low = guess + 1 16 | elif feedback == 'h': 17 | high = guess - 1 18 | print(f"I got it! Its {guess}") 19 | 20 | guess(1000) -------------------------------------------------------------------------------- /Hangman/hangman.py: -------------------------------------------------------------------------------- 1 | import random 2 | from words import words 3 | import string 4 | 5 | 6 | def get_valid_word(words): 7 | word = random.choice(words) # randomly chooses something from the list 8 | while '-' in word or ' ' in word: 9 | word = random.choice(words) 10 | 11 | return word.upper() 12 | 13 | 14 | def hangman(): 15 | word = get_valid_word(words) 16 | word_letters = set(word) # letters in the word 17 | alphabet = set(string.ascii_uppercase) 18 | used_letters = set() # what the user has guessed 19 | 20 | lives = 6 21 | 22 | # getting user input 23 | while len(word_letters) > 0 and lives > 0: 24 | # letters used 25 | # ' '.join(['a', 'b', 'cd']) --> 'a b cd' 26 | print('You have', lives, 'lives left and you have used these letters: ', ' '.join(used_letters)) 27 | 28 | # what current word is (ie W - R D) 29 | word_list = [letter if letter in used_letters else '-' for letter in word] 30 | print('Current word: ', ' '.join(word_list)) 31 | 32 | user_letter = input('Guess a letter: ').upper() 33 | if user_letter in alphabet - used_letters: 34 | used_letters.add(user_letter) 35 | if user_letter in word_letters: 36 | word_letters.remove(user_letter) 37 | print('') 38 | 39 | else: 40 | lives = lives - 1 # takes away a life if wrong 41 | print('\nYour letter,', user_letter, 'is not in the word.') 42 | 43 | elif user_letter in used_letters: 44 | print('\nYou have already used that letter. Guess another letter.') 45 | 46 | else: 47 | print('\nThat is not a valid letter.') 48 | 49 | # gets here when len(word_letters) == 0 OR when lives == 0 50 | if lives == 0: 51 | print('You died, sorry. The word was', word) 52 | else: 53 | print('YAY! You guessed the word', word, '!!') 54 | 55 | 56 | if __name__ == '__main__': 57 | hangman() 58 | -------------------------------------------------------------------------------- /Hangman/words.py: -------------------------------------------------------------------------------- 1 | words = ["aback","abaft","abandoned","abashed","aberrant","abhorrent","abiding","abject","ablaze","able","abnormal","aboard","aboriginal","abortive","abounding","abrasive","abrupt","absent","absorbed","absorbing","abstracted","absurd","abundant","abusive","acceptable","accessible","accidental","accurate","acid","acidic","acoustic","acrid","actually","ad hoc","adamant","adaptable","addicted","adhesive","adjoining","adorable","adventurous","afraid","aggressive","agonizing","agreeable","ahead","ajar","alcoholic","alert","alike","alive","alleged","alluring","aloof","amazing","ambiguous","ambitious","amuck","amused","amusing","ancient","angry","animated","annoyed","annoying","anxious","apathetic","aquatic","aromatic","arrogant","ashamed","aspiring","assorted","astonishing","attractive","auspicious","automatic","available","average","awake","aware","awesome","awful","axiomatic","bad","barbarous","bashful","bawdy","beautiful","befitting","belligerent","beneficial","bent","berserk","best","better","bewildered","big","billowy","bite-sized","bitter","bizarre","black","black-and-white","bloody","blue","blue-eyed","blushing","boiling","boorish","bored","boring","bouncy","boundless","brainy","brash","brave","brawny","breakable","breezy","brief","bright","bright","broad","broken","brown","bumpy","burly","bustling","busy","cagey","calculating","callous","calm","capable","capricious","careful","careless","caring","cautious","ceaseless","certain","changeable","charming","cheap","cheerful","chemical","chief","childlike","chilly","chivalrous","chubby","chunky","clammy","classy","clean","clear","clever","cloistered","cloudy","closed","clumsy","cluttered","coherent","cold","colorful","colossal","combative","comfortable","common","complete","complex","concerned","condemned","confused","conscious","cooing","cool","cooperative","coordinated","courageous","cowardly","crabby","craven","crazy","creepy","crooked","crowded","cruel","cuddly","cultured","cumbersome","curious","curly","curved","curvy","cut","cute","cute","cynical","daffy","daily","damaged","damaging","damp","dangerous","dapper","dark","dashing","dazzling","dead","deadpan","deafening","dear","debonair","decisive","decorous","deep","deeply","defeated","defective","defiant","delicate","delicious","delightful","demonic","delirious","dependent","depressed","deranged","descriptive","deserted","detailed","determined","devilish","didactic","different","difficult","diligent","direful","dirty","disagreeable","disastrous","discreet","disgusted","disgusting","disillusioned","dispensable","distinct","disturbed","divergent","dizzy","domineering","doubtful","drab","draconian","dramatic","dreary","drunk","dry","dull","dusty","dusty","dynamic","dysfunctional","eager","early","earsplitting","earthy","easy","eatable","economic","educated","efficacious","efficient","eight","elastic","elated","elderly","electric","elegant","elfin","elite","embarrassed","eminent","empty","enchanted","enchanting","encouraging","endurable","energetic","enormous","entertaining","enthusiastic","envious","equable","equal","erect","erratic","ethereal","evanescent","evasive","even","excellent","excited","exciting","exclusive","exotic","expensive","extra-large","extra-small","exuberant","exultant","fabulous","faded","faint","fair","faithful","fallacious","false","familiar","famous","fanatical","fancy","fantastic","far","far-flung","fascinated","fast","fat","faulty","fearful","fearless","feeble","feigned","female","fertile","festive","few","fierce","filthy","fine","finicky","first","five","fixed","flagrant","flaky","flashy","flat","flawless","flimsy","flippant","flowery","fluffy","fluttering","foamy","foolish","foregoing","forgetful","fortunate","four","frail","fragile","frantic","free","freezing","frequent","fresh","fretful","friendly","frightened","frightening","full","fumbling","functional","funny","furry","furtive","future","futuristic","fuzzy","gabby","gainful","gamy","gaping","garrulous","gaudy","general","gentle","giant","giddy","gifted","gigantic","glamorous","gleaming","glib","glistening","glorious","glossy","godly","good","goofy","gorgeous","graceful","grandiose","grateful","gratis","gray","greasy","great","greedy","green","grey","grieving","groovy","grotesque","grouchy","grubby","gruesome","grumpy","guarded","guiltless","gullible","gusty","guttural","habitual","half","hallowed","halting","handsome","handsomely","handy","hanging","hapless","happy","hard","hard-to-find","harmonious","harsh","hateful","heady","healthy","heartbreaking","heavenly","heavy","hellish","helpful","helpless","hesitant","hideous","high","highfalutin","high-pitched","hilarious","hissing","historical","holistic","hollow","homeless","homely","honorable","horrible","hospitable","hot","huge","hulking","humdrum","humorous","hungry","hurried","hurt","hushed","husky","hypnotic","hysterical","icky","icy","idiotic","ignorant","ill","illegal","ill-fated","ill-informed","illustrious","imaginary","immense","imminent","impartial","imperfect","impolite","important","imported","impossible","incandescent","incompetent","inconclusive","industrious","incredible","inexpensive","infamous","innate","innocent","inquisitive","insidious","instinctive","intelligent","interesting","internal","invincible","irate","irritating","itchy","jaded","jagged","jazzy","jealous","jittery","jobless","jolly","joyous","judicious","juicy","jumbled","jumpy","juvenile","kaput","keen","kind","kindhearted","kindly","knotty","knowing","knowledgeable","known","labored","lackadaisical","lacking","lame","lamentable","languid","large","last","late","laughable","lavish","lazy","lean","learned","left","legal","lethal","level","lewd","light","like","likeable","limping","literate","little","lively","lively","living","lonely","long","longing","long-term","loose","lopsided","loud","loutish","lovely","loving","low","lowly","lucky","ludicrous","lumpy","lush","luxuriant","lying","lyrical","macabre","macho","maddening","madly","magenta","magical","magnificent","majestic","makeshift","male","malicious","mammoth","maniacal","many","marked","massive","married","marvelous","material","materialistic","mature","mean","measly","meaty","medical","meek","mellow","melodic","melted","merciful","mere","messy","mighty","military","milky","mindless","miniature","minor","miscreant","misty","mixed","moaning","modern","moldy","momentous","motionless","mountainous","muddled","mundane","murky","mushy","mute","mysterious","naive","nappy","narrow","nasty","natural","naughty","nauseating","near","neat","nebulous","necessary","needless","needy","neighborly","nervous","new","next","nice","nifty","nimble","nine","nippy","noiseless","noisy","nonchalant","nondescript","nonstop","normal","nostalgic","nosy","noxious","null","numberless","numerous","nutritious","nutty","oafish","obedient","obeisant","obese","obnoxious","obscene","obsequious","observant","obsolete","obtainable","oceanic","odd","offbeat","old","old-fashioned","omniscient","one","onerous","open","opposite","optimal","orange","ordinary","organic","ossified","outgoing","outrageous","outstanding","oval","overconfident","overjoyed","overrated","overt","overwrought","painful","painstaking","pale","paltry","panicky","panoramic","parallel","parched","parsimonious","past","pastoral","pathetic","peaceful","penitent","perfect","periodic","permissible","perpetual","petite","petite","phobic","physical","picayune","pink","piquant","placid","plain","plant","plastic","plausible","pleasant","plucky","pointless","poised","polite","political","poor","possessive","possible","powerful","precious","premium","present","pretty","previous","pricey","prickly","private","probable","productive","profuse","protective","proud","psychedelic","psychotic","public","puffy","pumped","puny","purple","purring","pushy","puzzled","puzzling","quack","quaint","quarrelsome","questionable","quick","quickest","quiet","quirky","quixotic","quizzical","rabid","racial","ragged","rainy","rambunctious","rampant","rapid","rare","raspy","ratty","ready","real","rebel","receptive","recondite","red","redundant","reflective","regular","relieved","remarkable","reminiscent","repulsive","resolute","resonant","responsible","rhetorical","rich","right","righteous","rightful","rigid","ripe","ritzy","roasted","robust","romantic","roomy","rotten","rough","round","royal","ruddy","rude","rural","rustic","ruthless","sable","sad","safe","salty","same","sassy","satisfying","savory","scandalous","scarce","scared","scary","scattered","scientific","scintillating","scrawny","screeching","second","second-hand","secret","secretive","sedate","seemly","selective","selfish","separate","serious","shaggy","shaky","shallow","sharp","shiny","shivering","shocking","short","shrill","shut","shy","sick","silent","silent","silky","silly","simple","simplistic","sincere","six","skillful","skinny","sleepy","slim","slimy","slippery","sloppy","slow","small","smart","smelly","smiling","smoggy","smooth","sneaky","snobbish","snotty","soft","soggy","solid","somber","sophisticated","sordid","sore","sore","sour","sparkling","special","spectacular","spicy","spiffy","spiky","spiritual","spiteful","splendid","spooky","spotless","spotted","spotty","spurious","squalid","square","squealing","squeamish","staking","stale","standing","statuesque","steadfast","steady","steep","stereotyped","sticky","stiff","stimulating","stingy","stormy","straight","strange","striped","strong","stupendous","stupid","sturdy","subdued","subsequent","substantial","successful","succinct","sudden","sulky","super","superb","superficial","supreme","swanky","sweet","sweltering","swift","symptomatic","synonymous","taboo","tacit","tacky","talented","tall","tame","tan","tangible","tangy","tart","tasteful","tasteless","tasty","tawdry","tearful","tedious","teeny","teeny-tiny","telling","temporary","ten","tender","tense","tense","tenuous","terrible","terrific","tested","testy","thankful","therapeutic","thick","thin","thinkable","third","thirsty","thirsty","thoughtful","thoughtless","threatening","three","thundering","tidy","tight","tightfisted","tiny","tired","tiresome","toothsome","torpid","tough","towering","tranquil","trashy","tremendous","tricky","trite","troubled","truculent","true","truthful","two","typical","ubiquitous","ugliest","ugly","ultra","unable","unaccountable","unadvised","unarmed","unbecoming","unbiased","uncovered","understood","undesirable","unequal","unequaled","uneven","unhealthy","uninterested","unique","unkempt","unknown","unnatural","unruly","unsightly","unsuitable","untidy","unused","unusual","unwieldy","unwritten","upbeat","uppity","upset","uptight","used","useful","useless","utopian","utter","uttermost","vacuous","vagabond","vague","valuable","various","vast","vengeful","venomous","verdant","versed","victorious","vigorous","violent","violet","vivacious","voiceless","volatile","voracious","vulgar","wacky","waggish","waiting","wakeful","wandering","wanting","warlike","warm","wary","wasteful","watery","weak","wealthy","weary","well-groomed","well-made","well-off","well-to-do","wet","whimsical","whispering","white","whole","wholesale","wicked","wide","wide-eyed","wiggly","wild","willing","windy","wiry","wise","wistful","witty","woebegone","womanly","wonderful","wooden","woozy","workable","worried","worthless","wrathful","wretched","wrong","wry","yellow","yielding","young","youthful","yummy","zany","zealous","zesty","zippy","zonked","account","achiever","acoustics","act","action","activity","actor","addition","adjustment","advertisement","advice","aftermath","afternoon","afterthought","agreement","air","airplane","airport","alarm","amount","amusement","anger","angle","animal","ants","apparatus","apparel","appliance","approval","arch","argument","arithmetic","arm","army","art","attack","attraction","aunt","authority","babies","baby","back","badge","bag","bait","balance","ball","base","baseball","basin","basket","basketball","bat","bath","battle","bead","bear","bed","bedroom","beds","bee","beef","beginner","behavior","belief","believe","bell","bells","berry","bike","bikes","bird","birds","birth","birthday","bit","bite","blade","blood","blow","board","boat","bomb","bone","book","books","boot","border","bottle","boundary","box","boy","brake","branch","brass","breath","brick","bridge","brother","bubble","bucket","building","bulb","burst","bushes","business","butter","button","cabbage","cable","cactus","cake","cakes","calculator","calendar","camera","camp","can","cannon","canvas","cap","caption","car","card","care","carpenter","carriage","cars","cart","cast","cat","cats","cattle","cause","cave","celery","cellar","cemetery","cent","chalk","chance","change","channel","cheese","cherries","cherry","chess","chicken","chickens","children","chin","church","circle","clam","class","cloth","clover","club","coach","coal","coast","coat","cobweb","coil","collar","color","committee","company","comparison","competition","condition","connection","control","cook","copper","corn","cough","country","cover","cow","cows","crack","cracker","crate","crayon","cream","creator","creature","credit","crib","crime","crook","crow","crowd","crown","cub","cup","current","curtain","curve","cushion","dad","daughter","day","death","debt","decision","deer","degree","design","desire","desk","destruction","detail","development","digestion","dime","dinner","dinosaurs","direction","dirt","discovery","discussion","distance","distribution","division","dock","doctor","dog","dogs","doll","dolls","donkey","door","downtown","drain","drawer","dress","drink","driving","drop","duck","ducks","dust","ear","earth","earthquake","edge","education","effect","egg","eggnog","eggs","elbow","end","engine","error","event","example","exchange","existence","expansion","experience","expert","eye","eyes","face","fact","fairies","fall","fang","farm","fear","feeling","field","finger","finger","fire","fireman","fish","flag","flame","flavor","flesh","flight","flock","floor","flower","flowers","fly","fog","fold","food","foot","force","fork","form","fowl","frame","friction","friend","friends","frog","frogs","front","fruit","fuel","furniture","gate","geese","ghost","giants","giraffe","girl","girls","glass","glove","gold","government","governor","grade","grain","grandfather","grandmother","grape","grass","grip","ground","group","growth","guide","guitar","gun","hair","haircut","hall","hammer","hand","hands","harbor","harmony","hat","hate","head","health","heat","hill","history","hobbies","hole","holiday","home","honey","hook","hope","horn","horse","horses","hose","hospital","hot","hour","house","houses","humor","hydrant","ice","icicle","idea","impulse","income","increase","industry","ink","insect","instrument","insurance","interest","invention","iron","island","jail","jam","jar","jeans","jelly","jellyfish","jewel","join","judge","juice","jump","kettle","key","kick","kiss","kittens","kitty","knee","knife","knot","knowledge","laborer","lace","ladybug","lake","lamp","land","language","laugh","leather","leg","legs","letter","letters","lettuce","level","library","limit","line","linen","lip","liquid","loaf","lock","locket","look","loss","love","low","lumber","lunch","lunchroom","machine","magic","maid","mailbox","man","marble","mark","market","mask","mass","match","meal","measure","meat","meeting","memory","men","metal","mice","middle","milk","mind","mine","minister","mint","minute","mist","mitten","mom","money","monkey","month","moon","morning","mother","motion","mountain","mouth","move","muscle","name","nation","neck","need","needle","nerve","nest","night","noise","north","nose","note","notebook","number","nut","oatmeal","observation","ocean","offer","office","oil","orange","oranges","order","oven","page","pail","pan","pancake","paper","parcel","part","partner","party","passenger","payment","peace","pear","pen","pencil","person","pest","pet","pets","pickle","picture","pie","pies","pig","pigs","pin","pipe","pizzas","place","plane","planes","plant","plantation","plants","plastic","plate","play","playground","pleasure","plot","plough","pocket","point","poison","pollution","popcorn","porter","position","pot","potato","powder","power","price","produce","profit","property","prose","protest","pull","pump","punishment","purpose","push","quarter","quartz","queen","question","quicksand","quiet","quill","quilt","quince","quiver","rabbit","rabbits","rail","railway","rain","rainstorm","rake","range","rat","rate","ray","reaction","reading","reason","receipt","recess","record","regret","relation","religion","representative","request","respect","rest","reward","rhythm","rice","riddle","rifle","ring","rings","river","road","robin","rock","rod","roll","roof","room","root","rose","route","rub","rule","run","sack","sail","salt","sand","scale","scarecrow","scarf","scene","scent","school","science","scissors","screw","sea","seashore","seat","secretary","seed","selection","self","sense","servant","shade","shake","shame","shape","sheep","sheet","shelf","ship","shirt","shock","shoe","shoes","shop","show","side","sidewalk","sign","silk","silver","sink","sister","sisters","size","skate","skin","skirt","sky","slave","sleep","sleet","slip","slope","smash","smell","smile","smoke","snail","snails","snake","snakes","sneeze","snow","soap","society","sock","soda","sofa","son","song","songs","sort","sound","soup","space","spade","spark","spiders","sponge","spoon","spot","spring","spy","square","squirrel","stage","stamp","star","start","statement","station","steam","steel","stem","step","stew","stick","sticks","stitch","stocking","stomach","stone","stop","store","story","stove","stranger","straw","stream","street","stretch","string","structure","substance","sugar","suggestion","suit","summer","sun","support","surprise","sweater","swim","swing","system","table","tail","talk","tank","taste","tax","teaching","team","teeth","temper","tendency","tent","territory","test","texture","theory","thing","things","thought","thread","thrill","throat","throne","thumb","thunder","ticket","tiger","time","tin","title","toad","toe","toes","tomatoes","tongue","tooth","toothbrush","toothpaste","top","touch","town","toy","toys","trade","trail","train","trains","tramp","transport","tray","treatment","tree","trees","trick","trip","trouble","trousers","truck","trucks","tub","turkey","turn","twig","twist","umbrella","uncle","underwear","unit","use","vacation","value","van","vase","vegetable","veil","vein","verse","vessel","vest","view","visitor","voice","volcano","volleyball","voyage","walk","wall","war","wash","waste","watch","water","wave","waves","wax","way","wealth","weather","week","weight","wheel","whip","whistle","wilderness","wind","window","wine","wing","winter","wire","wish","woman","women","wood","wool","word","work","worm","wound","wren","wrench","wrist","writer","writing","yak","yam","yard","yarn","year","yoke","zebra","zephyr","zinc","zipper","zoo","accept","add","admire","admit","advise","afford","agree","alert","allow","amuse","analyse","announce","annoy","answer","apologise","appear","applaud","appreciate","approve","argue","arrange","arrest","arrive","ask","attach","attack","attempt","attend","attract","avoid","back","bake","balance","ban","bang","bare","bat","bathe","battle","beam","beg","behave","belong","bleach","bless","blind","blink","blot","blush","boast","boil","bolt","bomb","book","bore","borrow","bounce","bow","box","brake","branch","breathe","bruise","brush","bubble","bump","burn","bury","buzz","calculate","call","camp","care","carry","carve","cause","challenge","change","charge","chase","cheat","check","cheer","chew","choke","chop","claim","clap","clean","clear","clip","close","coach","coil","collect","colour","comb","command","communicate","compare","compete","complain","complete","concentrate","concern","confess","confuse","connect","consider","consist","contain","continue","copy","correct","cough","count","cover","crack","crash","crawl","cross","crush","cry","cure","curl","curve","cycle","dam","damage","dance","dare","decay","deceive","decide","decorate","delay","delight","deliver","depend","describe","desert","deserve","destroy","detect","develop","disagree","disappear","disapprove","disarm","discover","dislike","divide","double","doubt","drag","drain","dream","dress","drip","drop","drown","drum","dry","dust","earn","educate","embarrass","employ","empty","encourage","end","enjoy","enter","entertain","escape","examine","excite","excuse","exercise","exist","expand","expect","explain","explode","extend","face","fade","fail","fancy","fasten","fax","fear","fence","fetch","file","fill","film","fire","fit","fix","flap","flash","float","flood","flow","flower","fold","follow","fool","force","form","found","frame","frighten","fry","gather","gaze","glow","glue","grab","grate","grease","greet","grin","grip","groan","guarantee","guard","guess","guide","hammer","hand","handle","hang","happen","harass","harm","hate","haunt","head","heal","heap","heat","help","hook","hop","hope","hover","hug","hum","hunt","hurry","identify","ignore","imagine","impress","improve","include","increase","influence","inform","inject","injure","instruct","intend","interest","interfere","interrupt","introduce","invent","invite","irritate","itch","jail","jam","jog","join","joke","judge","juggle","jump","kick","kill","kiss","kneel","knit","knock","knot","label","land","last","laugh","launch","learn","level","license","lick","lie","lighten","like","list","listen","live","load","lock","long","look","love","man","manage","march","mark","marry","match","mate","matter","measure","meddle","melt","memorise","mend","mess up","milk","mine","miss","mix","moan","moor","mourn","move","muddle","mug","multiply","murder","nail","name","need","nest","nod","note","notice","number","obey","object","observe","obtain","occur","offend","offer","open","order","overflow","owe","own","pack","paddle","paint","park","part","pass","paste","pat","pause","peck","pedal","peel","peep","perform","permit","phone","pick","pinch","pine","place","plan","plant","play","please","plug","point","poke","polish","pop","possess","post","pour","practise","pray","preach","precede","prefer","prepare","present","preserve","press","pretend","prevent","prick","print","produce","program","promise","protect","provide","pull","pump","punch","puncture","punish","push","question","queue","race","radiate","rain","raise","reach","realise","receive","recognise","record","reduce","reflect","refuse","regret","reign","reject","rejoice","relax","release","rely","remain","remember","remind","remove","repair","repeat","replace","reply","report","reproduce","request","rescue","retire","return","rhyme","rinse","risk","rob","rock","roll","rot","rub","ruin","rule","rush","sack","sail","satisfy","save","saw","scare","scatter","scold","scorch","scrape","scratch","scream","screw","scribble","scrub","seal","search","separate","serve","settle","shade","share","shave","shelter","shiver","shock","shop","shrug","sigh","sign","signal","sin","sip","ski","skip","slap","slip","slow","smash","smell","smile","smoke","snatch","sneeze","sniff","snore","snow","soak","soothe","sound","spare","spark","sparkle","spell","spill","spoil","spot","spray","sprout","squash","squeak","squeal","squeeze","stain","stamp","stare","start","stay","steer","step","stir","stitch","stop","store","strap","strengthen","stretch","strip","stroke","stuff","subtract","succeed","suck","suffer","suggest","suit","supply","support","suppose","surprise","surround","suspect","suspend","switch","talk","tame","tap","taste","tease","telephone","tempt","terrify","test","thank","thaw","tick","tickle","tie","time","tip","tire","touch","tour","tow","trace","trade","train","transport","trap","travel","treat","tremble","trick","trip","trot","trouble","trust","try","tug","tumble","turn","twist","type","undress","unfasten","unite","unlock","unpack","untidy","use","vanish","visit","wail","wait","walk","wander","want","warm","warn","wash","waste","watch","water","wave","weigh","welcome","whine","whip","whirl","whisper","whistle","wink","wipe","wish","wobble","wonder","work","worry","wrap","wreck","wrestle","wriggle","x-ray","yawn","yell","zip","zoom"] 2 | -------------------------------------------------------------------------------- /Madlibs/madlib.py: -------------------------------------------------------------------------------- 1 | # Variables to store user prompts 2 | noun = input("Noun: ") 3 | adj = input("Adjective: ") 4 | noun2 = input("Noun: ") 5 | 6 | # Creating a string var to store madlib sentence 7 | madlib = f"After hiding the painting in his {noun} for two years, he grew {adj} and tried to sell it to a {noun2} in Mumbai, but was caught" 8 | 9 | # Printing the madlib 10 | print(madlib) -------------------------------------------------------------------------------- /Password Generator/Password Generator.py: -------------------------------------------------------------------------------- 1 | # Importing random module 2 | import random 3 | 4 | # Asking user for the length of the password to be generated 5 | pass_len = int(input("Enter the length of the password: ")) 6 | 7 | # Characters and symbols to generate password 8 | pass_data = "qwertyuiopasdfgjklzxcvbnm1234567890[];',./!@#$%^&*()_+:<>?" 9 | 10 | # Using random.sample() to collect random data from pass_data as a list & using .join() to join the list elements to form a string 11 | password = "".join(random.sample(pass_data, pass_len)) 12 | 13 | print(password) -------------------------------------------------------------------------------- /QR code generator/QR code generator.py: -------------------------------------------------------------------------------- 1 | # Run "pip install pyqrcode" before running this program 2 | import pyqrcode 3 | 4 | data = input("Enter the text or link to generate QR code: ") 5 | 6 | # Using pyqrcode.create() to create a qr code of the input data 7 | qr = pyqrcode.create(data) 8 | 9 | # Using .svg method to save the qr code as SVG file of provided name & scale 10 | qr.svg('qr_code.svg', scale = 8) -------------------------------------------------------------------------------- /Quiz Game/Quiz Game.py: -------------------------------------------------------------------------------- 1 | from questions import quiz 2 | 3 | 4 | def check_ans(question, ans, attempts, score): 5 | """ 6 | Takes the arguments, and confirms if the answer provided by user is correct. 7 | Converts all answers to lower case to make sure the quiz is not case sensitive. 8 | """ 9 | if quiz[question]['answer'].lower() == ans.lower(): 10 | print(f"Correct Answer! \nYour score is {score + 1}!") 11 | return True 12 | else: 13 | print(f"Wrong Answer :( \nYou have {attempts - 1} left! \nTry again...") 14 | return False 15 | 16 | 17 | def print_dictionary(): 18 | for question_id, ques_answer in quiz.items(): 19 | for key in ques_answer: 20 | print(key + ':', ques_answer[key]) 21 | 22 | 23 | def intro_message(): 24 | """ 25 | Introduces user to the quiz and rules, and takes an input from customer to start the quiz. 26 | Returns true regardless of any key pressed. 27 | """ 28 | print("Welcome to this fun food quiz! \nAre you ready to test your knowledge about food?") 29 | print("There are a total of 20 questions, you can skip a question anytime by typing 'skip'") 30 | input("Press any key to start the fun ;) ") 31 | return True 32 | 33 | 34 | # python project.py 35 | intro = intro_message() 36 | while True: 37 | score = 0 38 | for question in quiz: 39 | attempts = 3 40 | while attempts > 0: 41 | print(quiz[question]['question']) 42 | answer = input("Enter Answer (To move to the next question, type 'skip') : ") 43 | if answer == "skip": 44 | break 45 | check = check_ans(question, answer, attempts, score) 46 | if check: 47 | score += 1 48 | break 49 | attempts -= 1 50 | 51 | break 52 | 53 | print(f"Your final score is {score}!\n\n") 54 | print("Want to know the correct answers? Please see them below! ;)\n") 55 | print_dictionary() 56 | print("Thanks for playing! 💜") 57 | -------------------------------------------------------------------------------- /Quiz Game/questions.py: -------------------------------------------------------------------------------- 1 | quiz = { 2 | 1 : { 3 | "question" : "What is the first name of Iron Man?", 4 | "answer" : "Tony" 5 | }, 6 | 2 : { 7 | "question" : "Who is called the god of lightning in Avengers?", 8 | "answer" : "Thor" 9 | }, 10 | 3 : { 11 | "question" : "Who carries a shield of American flag theme in Avengers?", 12 | "answer" : "Captain America" 13 | }, 14 | 4 : { 15 | "question" : "Which avenger is green in color?", 16 | "answer" : "Hulk" 17 | }, 18 | 5 : { 19 | "question" : "Which avenger can change it's size?", 20 | "answer" : "AntMan" 21 | }, 22 | 6 : { 23 | "question" : "Which Avenger is red in color and has mind stone?", 24 | "answer" : "Vision" 25 | } 26 | } -------------------------------------------------------------------------------- /Rock Paper Scissors/rockpaperscissors.py: -------------------------------------------------------------------------------- 1 | import random 2 | 3 | def rock_paper_scissors(): 4 | player = input("What is your choice - 'r' for rock, 's' for scissor, 'p' for paper: ") 5 | choices = ['r','s','p'] 6 | opponent = random.choice(choices) 7 | 8 | if player == opponent: 9 | return print(f"Its a Tie! Choice is {opponent}") 10 | 11 | if check_win(player, opponent): 12 | return print(f"Yay! you won! Choice is {opponent}") 13 | 14 | if check_win(player, opponent) != True: 15 | return print(f"You lost! Choice is {opponent}") 16 | 17 | 18 | def check_win(user, computer): 19 | if (user == 'r' and computer == 's') or (user == 's' and computer == 'p') or (user == 'p' and computer == 'r'): 20 | return True 21 | 22 | rock_paper_scissors() -------------------------------------------------------------------------------- /Story Generator/Story Generator.py: -------------------------------------------------------------------------------- 1 | # Importing random module 2 | import random 3 | 4 | # Storing random data into lists to create story. 5 | when = ['A long time ago', 'Yesterday', 'Before you were born', 'In future', 'Before Thanos arrived'] 6 | who = ['Shazam', 'Iron Man', 'Batman', 'Superman', 'Captain America'] 7 | went = ['Arkham Asylum', 'Gotham City', 'Stark Tower', 'Bat Cave', 'Avengers HQ'] 8 | what = ['to eat a lot of cakes', 'to fight for justice', 'to steal ice cream', 'to dance'] 9 | 10 | # Using string concatenition & randome.choice() to print a random element from all the lists 11 | print(random.choice(when) + ', ' + random.choice(who) + ' went to ' + random.choice(went) + ' ' + random.choice(what) + '.') --------------------------------------------------------------------------------