From 4f089fe75d447c252fad25fec12c822a28360cc1 Mon Sep 17 00:00:00 2001 From: RameezHiro Date: Sun, 12 Oct 2025 15:40:48 +0530 Subject: [PATCH 1/8] Add Word scramble Game --- Python/Word_Scramble/Readme.md | 22 ++++++++++++++++++++++ Python/Word_Scramble/main.py | 23 +++++++++++++++++++++++ 2 files changed, 45 insertions(+) create mode 100644 Python/Word_Scramble/Readme.md create mode 100644 Python/Word_Scramble/main.py diff --git a/Python/Word_Scramble/Readme.md b/Python/Word_Scramble/Readme.md new file mode 100644 index 0000000..e40fd0f --- /dev/null +++ b/Python/Word_Scramble/Readme.md @@ -0,0 +1,22 @@ +🔤 Word Scramble Game + +A fun and simple Python word puzzle game where you have to guess the original word from its scrambled version! This project is great for beginners who want to practice loops, conditionals, functions, and randomization in Python. + + +🎮 Game Description + +The program randomly selects a word from a predefined list. + +It then scrambles the letters of the word and displays it to the player. + +The player has 3 attempts to guess the correct word. + +The game ends when the player guesses correctly or runs out of attempts. + + +🧩 Features + +✅ Randomly selects and scrambles words +✅ Limited attempts for guessing (default: 3) +✅ Provides feedback after each guess +✅ Displays the correct word if the player fails \ No newline at end of file diff --git a/Python/Word_Scramble/main.py b/Python/Word_Scramble/main.py new file mode 100644 index 0000000..4800523 --- /dev/null +++ b/Python/Word_Scramble/main.py @@ -0,0 +1,23 @@ +import random + +def scramble_word(word): + return "".join(random.sample(word, len(word))) + +words = ["python", "developer", "programming", "challenge"] +word = random.choice(words) +scrambled = scramble_word(word) + +print("Scrambled word:", scrambled) + +attempts = 3 +while attempts > 0: + guess = input("Guess the word: ").lower() + if guess == word: + print("Correct! ????") + break + else: + attempts -= 1 + print(f"Wrong! {attempts} attempts left.") + +if attempts == 0: + print(f"Game over! The correct word was {word}.") \ No newline at end of file From 6c11f41c5398d6c222f97be50f56ef9930a1b1eb Mon Sep 17 00:00:00 2001 From: RameezHiro Date: Sun, 12 Oct 2025 15:50:51 +0530 Subject: [PATCH 2/8] Add Quiz game --- Python/Quiz Game/main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/Python/Quiz Game/main.py b/Python/Quiz Game/main.py index 4155b29..6c2d793 100644 --- a/Python/Quiz Game/main.py +++ b/Python/Quiz Game/main.py @@ -27,6 +27,7 @@ else: print('Wrong Answer :(') + print('Thankyou for Playing this small quiz game, you attempted',score,"questions correctly!") mark=(score/total_questions)*100 From 656ea3f00f25098f67afbcec20ddae506ae58cfc Mon Sep 17 00:00:00 2001 From: RameezHiro Date: Sun, 12 Oct 2025 16:40:03 +0530 Subject: [PATCH 3/8] Add Word Scramble Game --- Python/Word_Scramble/Readme.md | 3 --- Python/Word_Scramble/main.py | 2 ++ 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Python/Word_Scramble/Readme.md b/Python/Word_Scramble/Readme.md index e40fd0f..fab9362 100644 --- a/Python/Word_Scramble/Readme.md +++ b/Python/Word_Scramble/Readme.md @@ -6,11 +6,8 @@ A fun and simple Python word puzzle game where you have to guess the original wo 🎮 Game Description The program randomly selects a word from a predefined list. - It then scrambles the letters of the word and displays it to the player. - The player has 3 attempts to guess the correct word. - The game ends when the player guesses correctly or runs out of attempts. diff --git a/Python/Word_Scramble/main.py b/Python/Word_Scramble/main.py index 4800523..034f445 100644 --- a/Python/Word_Scramble/main.py +++ b/Python/Word_Scramble/main.py @@ -1,5 +1,6 @@ import random + def scramble_word(word): return "".join(random.sample(word, len(word))) @@ -19,5 +20,6 @@ def scramble_word(word): attempts -= 1 print(f"Wrong! {attempts} attempts left.") + if attempts == 0: print(f"Game over! The correct word was {word}.") \ No newline at end of file From 442cea22fce7ba5c17f41cf4abd4b2a71faf2015 Mon Sep 17 00:00:00 2001 From: Shaikh Rameez <166215047+RameezHiro@users.noreply.github.com> Date: Sun, 12 Oct 2025 16:43:11 +0530 Subject: [PATCH 4/8] Delete Python/Word_Scramble/Readme.md --- Python/Word_Scramble/Readme.md | 19 ------------------- 1 file changed, 19 deletions(-) delete mode 100644 Python/Word_Scramble/Readme.md diff --git a/Python/Word_Scramble/Readme.md b/Python/Word_Scramble/Readme.md deleted file mode 100644 index fab9362..0000000 --- a/Python/Word_Scramble/Readme.md +++ /dev/null @@ -1,19 +0,0 @@ -🔤 Word Scramble Game - -A fun and simple Python word puzzle game where you have to guess the original word from its scrambled version! This project is great for beginners who want to practice loops, conditionals, functions, and randomization in Python. - - -🎮 Game Description - -The program randomly selects a word from a predefined list. -It then scrambles the letters of the word and displays it to the player. -The player has 3 attempts to guess the correct word. -The game ends when the player guesses correctly or runs out of attempts. - - -🧩 Features - -✅ Randomly selects and scrambles words -✅ Limited attempts for guessing (default: 3) -✅ Provides feedback after each guess -✅ Displays the correct word if the player fails \ No newline at end of file From b838577b3571cf5140bf315382a0de0c13d5878b Mon Sep 17 00:00:00 2001 From: RameezHiro Date: Sun, 12 Oct 2025 16:50:42 +0530 Subject: [PATCH 5/8] Add Word Scramble --- Python/Word_Scramble/Readme.md | 2 +- Python/Word_Scramble/main.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Python/Word_Scramble/Readme.md b/Python/Word_Scramble/Readme.md index fab9362..2a5a8a4 100644 --- a/Python/Word_Scramble/Readme.md +++ b/Python/Word_Scramble/Readme.md @@ -1,6 +1,6 @@ 🔤 Word Scramble Game -A fun and simple Python word puzzle game where you have to guess the original word from its scrambled version! This project is great for beginners who want to practice loops, conditionals, functions, and randomization in Python. +A fun and simple Python word puzzle game where you have to guess the original word from its scrambled version!. This project is great for beginners who want to practice loops, conditionals, functions, and randomization in Python. 🎮 Game Description diff --git a/Python/Word_Scramble/main.py b/Python/Word_Scramble/main.py index 034f445..8f61d08 100644 --- a/Python/Word_Scramble/main.py +++ b/Python/Word_Scramble/main.py @@ -10,6 +10,7 @@ def scramble_word(word): print("Scrambled word:", scrambled) + attempts = 3 while attempts > 0: guess = input("Guess the word: ").lower() From 588761ac41c55af7231c5ad767bbca89d95963af Mon Sep 17 00:00:00 2001 From: Shaikh Rameez <166215047+RameezHiro@users.noreply.github.com> Date: Sun, 12 Oct 2025 16:55:27 +0530 Subject: [PATCH 6/8] Delete Python/Quiz Game/main.py --- Python/Quiz Game/main.py | 37 ------------------------------------- 1 file changed, 37 deletions(-) delete mode 100644 Python/Quiz Game/main.py diff --git a/Python/Quiz Game/main.py b/Python/Quiz Game/main.py deleted file mode 100644 index 6c2d793..0000000 --- a/Python/Quiz Game/main.py +++ /dev/null @@ -1,37 +0,0 @@ -print('Welcome to AskPython Quiz') - -answer=input('Are you ready to play the Quiz ? (yes/no) :') -score=0 -total_questions=3 - -if answer.lower()=='yes': - answer=input('Question 1: What is your Favourite programming language?') - if answer.lower()=='python': - score += 1 - print('correct') - else: - print('Wrong Answer :(') - - - answer=input('Question 2: Do you follow any author on AskPython? ') - if answer.lower()=='yes': - score += 1 - print('correct') - else: - print('Wrong Answer :(') - - answer=input('Question 3: What is the name of your favourite website for learning Python?') - if answer.lower()=='askpython': - score += 1 - print('correct') - else: - print('Wrong Answer :(') - - -print('Thankyou for Playing this small quiz game, you attempted',score,"questions correctly!") - -mark=(score/total_questions)*100 - -print('Marks obtained:',mark) - -print('BYE!') \ No newline at end of file From a3a741e33e6b507ffae5b611ceda0472f84c0ce7 Mon Sep 17 00:00:00 2001 From: Shaikh Rameez <166215047+RameezHiro@users.noreply.github.com> Date: Sun, 12 Oct 2025 16:57:00 +0530 Subject: [PATCH 7/8] Delete Python/Word_Scramble/main.py --- Python/Word_Scramble/main.py | 25 ------------------------- 1 file changed, 25 deletions(-) delete mode 100644 Python/Word_Scramble/main.py diff --git a/Python/Word_Scramble/main.py b/Python/Word_Scramble/main.py deleted file mode 100644 index 034f445..0000000 --- a/Python/Word_Scramble/main.py +++ /dev/null @@ -1,25 +0,0 @@ -import random - - -def scramble_word(word): - return "".join(random.sample(word, len(word))) - -words = ["python", "developer", "programming", "challenge"] -word = random.choice(words) -scrambled = scramble_word(word) - -print("Scrambled word:", scrambled) - -attempts = 3 -while attempts > 0: - guess = input("Guess the word: ").lower() - if guess == word: - print("Correct! ????") - break - else: - attempts -= 1 - print(f"Wrong! {attempts} attempts left.") - - -if attempts == 0: - print(f"Game over! The correct word was {word}.") \ No newline at end of file From 761062d7e32adb709b77e09d214780d7097874d5 Mon Sep 17 00:00:00 2001 From: RameezHiro Date: Sat, 18 Oct 2025 18:46:38 +0530 Subject: [PATCH 8/8] Added Readme.md for Quiz Game --- Python/Quiz Game/Readme.md | 2 +- Python/Quiz Game/main.py | 38 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 Python/Quiz Game/main.py diff --git a/Python/Quiz Game/Readme.md b/Python/Quiz Game/Readme.md index 7a0f3ee..9c4f902 100644 --- a/Python/Quiz Game/Readme.md +++ b/Python/Quiz Game/Readme.md @@ -26,4 +26,4 @@ Displaying formatted output 📚 Author -Developed by RAMEEZ as a beginner Python project to improve interactive programming skills and logical thinking. \ No newline at end of file +Developed by RameezHiro as a beginner Python project to improve interactive programming skills and logical thinking. \ No newline at end of file diff --git a/Python/Quiz Game/main.py b/Python/Quiz Game/main.py new file mode 100644 index 0000000..58f3899 --- /dev/null +++ b/Python/Quiz Game/main.py @@ -0,0 +1,38 @@ +print('Welcome to AskPython Quiz') + + +answer=input('Are you ready to play the Quiz ? (yes/no) :') +score=0 +total_questions=3 + +if answer.lower()=='yes': + answer=input('Question 1: What is your Favourite programming language?') + if answer.lower()=='python': + score += 1 + print('correct') + else: + print('Wrong Answer :(') + + + answer=input('Question 2: Do you follow any author on AskPython? ') + if answer.lower()=='yes': + score += 1 + print('correct') + else: + print('Wrong Answer :(') + + answer=input('Question 3: What is the name of your favourite website for learning Python?') + if answer.lower()=='askpython': + score += 1 + print('correct') + else: + print('Wrong Answer :(') + + +print('Thankyou for Playing this small quiz game, you attempted',score,"questions correctly!") + +mark=(score/total_questions)*100 + +print('Marks obtained:',mark) + +print('BYE!') \ No newline at end of file