Skip to content

Moonkeymann/Final-Project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 

Repository files navigation

NUMBER QUEST - Final Python Project

Created by: Numan Syed

Overview

Number Quest is a simple Python mini-game designed using only the concepts learned in class:

  • Loops
  • Ranges
  • Lists
  • Functions
  • Conditionals (if/elif/else)
  • Input/Output
  • Random numbers
  • Basic math

The project contains three mini-challenges:

  1. Guess The Number
  2. Range Challenge
  3. Even or Odd Detector

Concepts Used (Based on Class Examples)

Loops

  • for i in range(n)
  • while guess != secret

Ranges

  • range(n + 1)

Lists

  • numbers = [random.randint(1, 20) for _ in range(5)]

Functions

  • def guess_the_number():
  • def main():

Conditionals

  • if guess == secret
  • elif num % 2 == 0

Random

  • random.randint(1, 20)

Input & Output

  • input("Enter your guess: ")
  • print() statements

Time Delays (from classroom Godrick example)

  • time.sleep(0.1)

How to Run

  1. Install Python 3
  2. Run the program: example.py

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors