Back

Sanskar

Keen Learner and Exp... • 1d

Day 7 of learning python as a beginner. Topic: making a dynamic to-do list. Yesterday I created a basic to-do list and some people suggested and gave me a challenge that I should make it more dynamic so that the user can choose the day where he want to add the tasks. I was introduced with dictionaries during a process and I figured out that I can use it as a type of database to store the list of various days. Dictionary is like a collection of data that stores key value pairs. I then used def functions to create two functions first for creating a loop which lets the user enter to enter five tasks in each day. The second function is the actual logic of the whole to-do list. It takes user input and compares it with the days tupple to check which day the user wants to add his tasks in and if the user has entered a valid day. If the user has entered a valid day he is then asked to enter five tasks (he can also leave them empty - I used this for testing the whole program - cause adding each tasks for completing the whole program is time consuming, do tell me how you guys test your programs). If the user has not enter a valid day then the programs ask him to add a valid day and then it gets verified and he can start adding tasks however on the second time also if he have entered an invalid day then the program exits and he is prompted with a question if he want to continue adding task - yes/no. This whole process repeats 7 times because there are 7 days in a week and if the user wants he can continue adding task to more days and can also leave in between. He will also get a notification if he has assigned tasks to all the days. I request all the amazing people who gave their suggestion and challenge to verify whether I was able to complete the challenge or not? please do tell me what I should have done if I wasn't able to complete the challenge and I would really appreciate if you have some suggetions for me to improve my code. Here's my code and it's four results I just talked about.

1 Reply
1
5
Replies (1)

More like this

Recommendations from Medial

Image Description

Divyam Gupta

Building products, l... • 2m

Day 10 of launching my Saas product. We create customised story books for kids. - 12 users - 1 sign up - 0 paid user Spoke to a big vendor about selling this B2B. If he likes the idea and product I can have a huge deal at the very start.

2 Replies
3
Image Description
Image Description

AKSHAY GADDI

MERN stack and RactN... • 9m

Did anyone notice the Idea behind the startup showcase by 'Medial'? I think it's a great way to bring in more customers as the applicant would be greedy to win and they would ask their friends to install the app and vote for them Then what if the

See More
5 Replies
1
11
Image Description
Image Description

varun ravipati

Hey I am on Medial • 10m

Hi guys I am planning to be a seller on Amazon. I am thinking of selling some usb cables first to enter into the market and I am thinking of adding a product of some other category. Can u guys give me a suggestion on what to list for selling...

4 Replies
5
Image Description

Sanskar

Keen Learner and Exp... • 6d

Day 2 of learning python as a beginner. Topic: Conditional Expression Conditional expression pose a condition (if and Else statements). They help program take decision based on the condition given. They can be used inside a function or while assign

See More
4 Replies
4
15
Image Description

Ashish Ahirwar

Aspiring entrepreneu... • 9m

D-mart is superior. I mean you just can't beat the pricing and if you start shopping for your daily household items you won't go anywhere else the day you enter the store

1 Reply
3

Jatin Ahirwar

Full Stack Developer • 11m

🗂️Day 27 of the 30-day Question Mania challenge with Hitesh Choudhary Sir! Today, I focused on building a Task Management App, a project that honed my skills in creating interactive and user-friendly applications. Here’s what I achieved: 🔹 Pro

See More
Reply
1
Image Description
Image Description

Piyush Singh

Full Stack Dev | Web... • 1y

If you are struggling to stay focused? Here are simple tips that have helped me: 1. Cut distractions: Turn off notifications. 2. Plan ahead: Decide tasks the night before. 3. Set daily goals: Focus on a few tasks. 4. Avoid multitasking: Do one thing

See More
3 Replies
1
9
Image Description
Image Description

Rohith R

I help businesses to... • 7m

He has a valid point in my opinion!. He is not even compelling everybody to work 70 hours, rather he is giving a reason to work. Today's youths are taking too much care of work life balance. You see, so many young entrepreneurs fail, Why?. They not

See More
9 Replies
2
20
Image Description
Image Description

Ansh Kadam

Founder & CEO at Bui... • 6m

I heard a story the other day that can completely stop your productive procrastination. Two men decide to learn to fish. The first man says, “Time to fish! But first, I need the perfect custom rod, a top-tier fishing coach, and at least six months

See More
12 Replies
4
16

Download the medial app to read full posts, comements and news.