Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions Book_Title_Generator/README.md.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Book Title Generator

A fun and creative Python script that generates random book titles by combining descriptive adjectives with imaginative nouns — perfect for writers, game developers, or anyone looking for inspiration!

## Features

- Randomly combines adjectives and nouns to form unique titles.

- Includes fantasy and mystery themed words for creative variety.

- Allows you to generate multiple titles at once.

- Simple, beginner-friendly Python code using only the built-in random module.

## Produces titles like:

- The Enchanted Dragon

- The Hidden Kingdom

- The Cursed Mirror

- The Fiery Sword

## How It Works

- The program stores large lists of adjectives and nouns.

- When you run the script, you can choose:

1 → Generate new titles

2 → Exit the program

- If you choose 1, you’ll be asked how many titles to generate.

- Each title is printed in the format:
The <Adjective> <Noun>

### Example output:

Enter choice:
1-Title
2-Exit
> 1
Enter number of titles to generate: 3

The Enchanted Kingdom
The Hidden Shadow
The Fiery Sword

## Usage

Run book_title_generator.py.
- Enter the number of titles you want to generate.
- Outputs as many titles as you input.
88 changes: 88 additions & 0 deletions Book_Title_Generator/book_title_generator.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
# Book Title Generator

import random

adjectives = [
# Appearance
"beautiful", "elegant", "bright", "shiny", "colorful", "dark", "tall", "short", "sleek", "rugged",
"attractive", "plain", "glossy", "sparkling", "dull", "radiant", "faded", "bulky", "slender", "graceful",

# Personality / Emotion
"kind", "cheerful", "brave", "honest", "stubborn", "gentle", "nervous", "patient", "ambitious", "thoughtful",
"confident", "polite", "rude", "moody", "generous", "optimistic", "pessimistic", "loyal", "shy", "curious",

# Intensity / Quantity
"abundant", "scarce", "few", "many", "several", "immense", "tiny", "enormous", "slight", "significant",

# Condition / Quality
"clean", "dirty", "broken", "smooth", "rough", "stable", "fragile", "reliable", "efficient", "defective",
"active", "passive", "damaged", "operational", "sturdy", "delicate", "firm", "flexible", "weak", "powerful",

# Time / Age
"ancient", "new", "recent", "modern", "young", "old", "early", "late", "timeless", "temporary",

# Environment / Setting
"noisy", "quiet", "crowded", "empty", "peaceful", "stormy", "warm", "chilly", "humid", "dry",

# Abstract Qualities
"creative", "logical", "innovative", "complex", "simple", "chaotic", "organized", "efficient", "consistent", "unpredictable",

# Value / Worth
"cheap", "expensive", "valuable", "worthless", "affordable", "luxurious", "rare", "common", "desirable", "precious",

# Fantasy / Mystery / Mythical
"enchanted", "mystical", "cursed", "divine", "ethereal", "ghostly", "shadowy", "magical", "mysterious",
"sacred", "forbidden", "arcane", "legendary", "heroic", "sinister", "haunted", "hidden", "invisible",
"fiery", "icy", "eternal", "royal", "darkened", "spectral", "luminous", "secretive", "celestial", "ancient"
]

nouns = [
# People & Roles
"teacher", "student", "artist", "engineer", "doctor", "manager", "child", "friend", "neighbor", "leader",

# Places
"city", "village", "country", "school", "office", "park", "restaurant", "mountain", "beach", "museum",

# Objects / Things
"book", "phone", "computer", "chair", "table", "car", "key", "lamp", "bottle", "clock",

# Animals
"dog", "cat", "bird", "horse", "elephant", "tiger", "lion", "fish", "rabbit", "monkey",

# Nature
"tree", "flower", "river", "ocean", "hill", "stone", "cloud", "rain", "sun", "wind",

# Ideas / Abstract Concepts
"freedom", "love", "happiness", "courage", "knowledge", "power", "truth", "success", "peace", "justice",

# Time & Events
"day", "night", "morning", "evening", "week", "month", "year", "festival", "meeting", "celebration",

# Food & Drink
"apple", "bread", "cake", "coffee", "tea", "pizza", "sandwich", "milk", "water", "chocolate",

# Technology & Tools
"machine", "engine", "robot", "network", "database", "software", "hardware", "screen", "cable", "keyboard",

# Economy & Work
"job", "company", "market", "business", "salary", "investment", "customer", "product", "service", "trade",

# Mystery / Crime / Supernatural
"detective", "clue", "secret", "shadow", "ghost", "whisper", "potion", "curse", "riddle", "villain",
"mystery", "labyrinth", "mirror", "symbol", "prophecy", "assassin", "spy", "fog", "mask", "illusion",

# Fantasy / Magic / Myth
"dragon", "wizard", "sword", "castle", "kingdom", "elf", "dwarf", "goblin", "troll", "unicorn",
"phoenix", "spell", "crystal", "portal", "realm", "guardian", "knight", "crown", "treasure", "spirit"
]

while(True):
ch = int(input("Enter choice:\n1-Title\n2-Exit\n"))
if ch == 2:
break
n = int(input("Enter number of titles to generate: "))
for i in range(n):
adjective = random.choice(adjectives)
noun = random.choice(nouns)
print(f"The {adjective.capitalize()} {noun.capitalize()}")
print()
10 changes: 10 additions & 0 deletions Spam_Detector/README.md.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Spam Detector

This python script detects if the text given is to be flagged as spam or not.
It uses simple text keyword based classification to identify spam mails and messages.

## Usage

- Run spam_detector.py.
- Enter text, mail, or messages that you would like to check for spam.
- Outputs whether it is a spam, and the words that flag it as spam or not spammy.
75 changes: 75 additions & 0 deletions Spam_Detector/spam_detector.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# Tiny Spam Detector

keywords = [
# Frequent
"click", "download", "otp", "loan", "verify",
"free", "offer", "win", "prize", "money",
"urgent", "limited", "credit", "account", "password",

# Marketing / urgency words
"100% more", "100% free", "100% satisfied", "additional income", "be your own boss",
"best price", "big bucks", "billion", "cash bonus", "cents on the dollar",
"consolidate debt", "double your cash", "double your income", "earn extra cash",
"earn money", "eliminate bad credit", "extra cash", "extra income", "expect to earn",
"fast cash", "financial freedom", "free access", "free consultation", "free gift",
"free hosting", "free info", "free investment", "free membership", "free money",
"free preview", "free quote", "free trial", "full refund", "get out of debt",
"get paid", "giveaway", "guaranteed", "increase sales", "increase traffic",
"incredible deal", "lower rates", "lowest price", "make money", "million dollars",
"miracle", "money back", "once in a lifetime", "one time", "pennies a day",
"potential earnings", "promise", "pure profit", "risk-free", "satisfaction guaranteed",
"save big money", "save up to", "special promotion",

# Urgency phrases
"act now", "apply now", "become a member", "call now", "click below", "click here",
"get it now", "do it today", "don’t delete", "exclusive deal", "get started now",
"important information regarding", "information you requested", "instant",
"limited time", "new customers only", "order now", "please read", "see for yourself",
"sign up free", "take action", "this won’t last", "urgent", "what are you waiting for?",
"while supplies last", "will not believe your eyes", "winner", "winning",
"you are a winner", "you have been selected",

# Shady / scammy behavior
"bulk email", "buy direct", "cancel at any time", "check or money order",
"congratulations", "confidentiality", "cures", "dear friend", "direct email",
"direct marketing", "hidden charges", "human growth hormone", "internet marketing",
"lose weight", "mass email", "meet singles", "multi-level marketing", "no catch",
"no cost", "no credit check", "no fees", "no gimmick", "no hidden costs",
"no hidden fees", "no interest", "no investment", "no obligation",
"no purchase necessary", "no questions asked", "no strings attached",
"not junk", "notspam", "obligation", "passwords", "requires initial investment",
"social security number", "this isn’t a scam", "this isn’t junk", "this isn’t spam",
"undisclosed", "unsecured credit", "unsecured debt", "unsolicited", "valium",
"viagra", "vicodin", "we hate spam", "weight loss", "xanax",

# Legal / marketing jargon
"accept credit cards", "ad", "all new", "as seen on", "bargain", "beneficiary",
"billing", "bonus", "cards accepted", "cash", "certified", "cheap", "claims",
"clearance", "compare rates", "credit card offers", "deal", "debt", "discount",
"fantastic", "in accordance with laws", "income", "investment", "join millions",
"lifetime", "loans", "luxury", "marketing solution", "message contains",
"mortgage rates", "name brand", "offer", "online marketing", "opt in", "pre-approved",
"quote", "rates", "refinance", "removal", "reserves the right", "score",
"search engine", "sent in compliance", "subject to", "terms and conditions",
"trial", "unlimited", "warranty", "web traffic", "work from home"
]

while(True):
ch = int(input("Enter choice:\n1-Text\n2-Exit\n"))
if ch == 2:
break
text = input("Enter text: ")
spam = 0
found = []
for keyword in keywords:
if keyword in text.lower():
spam += 1
found.append(keyword)
words = text.split()
if(spam / len(words) > 0.1):
print("Spam Detected.")
print("Why? ", ", ".join(found))
print()
else:
print("Not Spammy.")
print()