From 2de6829c102454b83c06296b5dc675c2c9511a11 Mon Sep 17 00:00:00 2001 From: AdyaTech Date: Thu, 7 May 2026 16:35:48 +0530 Subject: [PATCH] Contributing my Python project by the name of Story Generator in this repository. --- Story-Generator/story.py | 51 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 Story-Generator/story.py diff --git a/Story-Generator/story.py b/Story-Generator/story.py new file mode 100644 index 0000000..627ff7c --- /dev/null +++ b/Story-Generator/story.py @@ -0,0 +1,51 @@ +import random +when = [ + "A few years ago", + "Yesterday", + "Last night", + "A long time ago", + "On 20th January" +] +who = [ + "a rabbit", + "an elephant", + "a mouse", + "a turtle", + "a cat" +] +names = [ + "Ali", + "Miriam", + "Daniel", + "Houuk", + "Starwalker" +] +places = [ + "Barcelona", + "India", + "Germany", + "Venice", + "England" +] +went_to = [ + "cinema", + "university", + "seminar", + "school", + "laundry" +] +happened = [ + "made a lot of friends", + "ate a burger", + "found a secret key", + "solved a mystery", + "wrote a book" +] +story = ( + f"{random.choice(when)}, " + f"{random.choice(names)} the {random.choice(who)} " + f"from {random.choice(places)} went to the " + f"{random.choice(went_to)} and " + f"{random.choice(happened)}." +) +print(story) \ No newline at end of file