Skip to content

Instantly share code, notes, and snippets.

View R3DHULK's full-sized avatar
🏠
Working from home

Sumalya Chatterjee R3DHULK

🏠
Working from home
View GitHub Profile
@R3DHULK
R3DHULK / monster-truck.py
Created March 21, 2023 04:56
Monster Truck In Python
import pygame
import random
# Initialize Pygame
pygame.init()
# Set window dimensions and title
window_width = 800
window_height = 600
window_title = 'Bike Racing Game'
@R3DHULK
R3DHULK / frogger-gui.py
Created March 21, 2023 04:50
GUI Based Frogger Game In Python
import pygame
import random
# Initialize Pygame
pygame.init()
# Set the window dimensions and create the window
window_width = 600
window_height = 600
screen = pygame.display.set_mode((window_width, window_height))
@R3DHULK
R3DHULK / box-catch.py
Created March 21, 2023 04:31
Box Catching Game In Python
import pygame
import random
# Initialize pygame
pygame.init()
# Set the screen size
screen_width = 640
screen_height = 480
screen = pygame.display.set_mode((screen_width, screen_height))
@R3DHULK
R3DHULK / detective-game-gui.py
Created March 10, 2023 18:06
Detective Game In GUI In Python
import tkinter as tk
from tkinter import messagebox
import random
# List of suspects
suspects = ["Aiden", "Becky", "Charlie", "David", "Ella"]
# List of locations
locations = ["Office", "Kitchen", "Bedroom", "Bathroom", "Living Room"]
@R3DHULK
R3DHULK / volleyball-game-simulator-gui.py
Created March 10, 2023 18:02
Volleyball Game Simulator In GUI In Python
import tkinter as tk
import random
# Set up the GUI window
root = tk.Tk()
root.title("Volleyball Game Simulator")
# Set up the labels and entry fields for team skill levels
label1 = tk.Label(root, text="Team 1 Skill Level:")
label1.grid(row=0, column=0)
@R3DHULK
R3DHULK / football-game-simulator-gui.py
Created March 10, 2023 17:59
Football Game Simulator In GUI In Python
import tkinter as tk
import random
# Set up the GUI window
root = tk.Tk()
root.title("Football Game Simulator")
# Set up the labels and entry fields for team skill levels
label1 = tk.Label(root, text="Team 1 Skill Level:")
label1.grid(row=0, column=0)
@R3DHULK
R3DHULK / guess-the-number-gui.py
Created March 10, 2023 17:53
GUI Based Guess The Number Game In Python
import random
import tkinter as tk
from tkinter import messagebox
class GuessNumberGame:
def __init__(self, master):
self.master = master
self.master.title("Guess the Number Game")
self.secret_number = random.randint(1, 100)
@R3DHULK
R3DHULK / guess-the-number.r
Created March 10, 2023 17:45
Text Based Guess The Number Game In R
# Generate a random number between 1 and 100
random_number <- sample(1:100, 1)
# Initialize the number of guesses
num_guesses <- 0
# Loop until the user correctly guesses the number
while (TRUE) {
# Prompt the user to enter a guess
user_guess <- readline(prompt = "Guess a number between 1 and 100: ")
@R3DHULK
R3DHULK / guess-the-number.py
Created March 10, 2023 17:41
Text Based Guess The Number Game In Python
import random
import math
# Taking Inputs
lower = int(input("Enter Lower bound:- "))
# Taking Inputs
upper = int(input("Enter Upper bound:- "))
# generating random number between
# the lower and upper
@R3DHULK
R3DHULK / simon_says_gui.py
Created March 10, 2023 11:00
GUI Based Simon Says In Python
import tkinter as tk
import random
# Define colors
COLORS = {"red": "#ff0000", "blue": "#0000ff",
"green": "#00ff00", "yellow": "#ffff00"}
class SimonSaysGame:
def __init__(self, master):