📌 Day 11 of My #50DaysOfPython Challenge 🐍 🔹 Task: Count the Number of Vowels and Consonants in a String Today’s challenge focused on string manipulation — a core concept in Python programming. I built a simple program that takes a word or sentence as input and counts how many vowels and consonants it contains. 🧠 What I Learned: How to iterate through characters in a string The use of sets for faster lookup ({'a', 'e', 'i', 'o', 'u'}) Using .lower() and .isalpha() for clean, accurate results The importance of filtering only alphabetic characters 🧪 Example: Input: Hello World Output: Vowels: 3 Consonants: 7 Working with strings is always fun because it improves both logic and attention to detail 🔤 Excited to keep building something new each day 🚀 #Python #CodingChallenge #50DaysOfPython #ProblemSolving #LearningJourney #CodeNewbie
More Relevant Posts
-
--- 🚀 Exploring Python Logic Operators! 🐍 Today, I spent some time experimenting with Python’s logical operators like and, or, and &. It’s fascinating how operator precedence and short-circuiting can change the output of expressions — even small changes like the order of conditions can make a big difference! 💡 Key takeaway: Understanding how Python evaluates expressions helps write cleaner and more efficient code. Here’s a glimpse of my practice in IDLE 👇 #Python #LearningInPublic #CodingJourney #Programming #LogicBuilding #TechLearning ---
To view or add a comment, sign in
-
-
Let’s Talk About Loops in Python! Loops help us repeat actions efficiently instead of writing the same code again and again.. Here are the two main types of loops 👇 🔹 for loop – Used when you know how many times to iterate. for i in range(5): print(i) 🔹 while loop – Used when you don’t know the exact count and want to loop until a condition is true. count = 0 while count < 5: print(count) count += 1 Loops make code shorter, cleaner, and smarter which is an essential skill for every Python learner! #Python #Coding #Programming #LearnPython #Loops #TechCommunity
To view or add a comment, sign in
-
Today I solved an interesting Set Theory problem using Python 💻 The task was to determine whether one set is a subset, superset, or equal to another — without using any built-in functions! 🧩 Problem Statement: Write a Python program to check whether Set1 is a subset, superset, or equal to Set2. If none of these, print "No subset or superset relation". 🧠 Approach (without built-ins): #Python #DSA #CodingJourney #ProblemSolving #MERNStackDeveloper #100DaysOfCode #LearnByBuilding #CodeNewbie #ProgrammingChallenge #PythonDevelopers #LinkedInCodingCommunity
To view or add a comment, sign in
-
-
🚀 Learning Python Step by Step! Today, I explored two important Python concepts — Dictionary and Range. 📘 A dictionary helps store data in key–value pairs, while range() makes looping and iteration efficient. Both are simple yet powerful features that form the foundation of data handling and automation in Python. I’ve shared my notebook where I practiced and documented both topics — feel free to check it out! #Python #DataScience #LearningJourney #Coding #JupyterNotebook #PythonBasics
To view or add a comment, sign in
-
🚀 **Day 38 of my 50 Days Code Challenge!** Today, I explored **Nested Loops** in Python — loops inside loops! 🔁 Understanding how outer and inner loops work together helped me see how powerful and flexible iteration can be. 🧠 **Key learnings:** * Outer loops control the main iteration. * Inner loops repeat completely for each iteration of the outer loop. * Useful in tasks like working with matrices, patterns, and combinations. 💻 Example: Using nested `for` loops to print values from two different ranges. Each outer value runs the entire inner loop — a great way to understand structured repetition in Python. #100DaysOfCode #Python #CodingChallenge #LearningJourney #NestedLoops #CodeEveryday #WomenInTech
To view or add a comment, sign in
-
-
In this beginner-friendly Python guide, I’ve explained how to calculate the average of numbers using both hardcoded values and user input. You’ll learn the logic step-by-step, understand how sum() and len() work, and see a complete dry run to strengthen your logic-building skills. Perfect for anyone starting their Python journey! 🐍✨ #Python #CodingForBeginners #PythonTutorial #LearnToCode #DataScience #ProgrammingLogic #PythonBasics #BeginnerFriendly #CodeLearning
To view or add a comment, sign in
-
💻 100 Days of Python Challenge – Day 4: loops For Loop A for loop iterates over a given sequence such as a list, tuple, string, or range. It executes a block of code once for each item in the sequence. While Loop A while loop repeatedly executes a block of code as long as a specified condition is true. It is useful when the number of iterations is not known beforehand. #Python #ForLoop #WhileLoop #PythonProgramming #100DaysOfCode #LearnPython #CodingJourney #CodeNewbie #ProgrammingBasics #PythonLoops #DeveloperInProgress
To view or add a comment, sign in
-
♟️ Day 14 – Python Practice Problems: 👾Exception & File Handling... Today, I focused on mastering error handling in Python using try, except, and finally blocks. 🥷🏻 Topics Covered: Handling ZeroDivisionError while performing division Managing multiple exceptions (ValueError, ZeroDivisionError) Using finally to ensure clean-up or completion messages 🧠 Key Takeaway: Always anticipate potential errors and handle them gracefully — it makes your code more robust and user-friendly. 💻 #Python #CodingPractice #ErrorHandling #LearnCoding #100DaysOfCode
To view or add a comment, sign in
-
-
📌 Day 6 of My #50DaysOfPython Challenge 🐍 Today’s task was to check whether a number is Prime or Not. 🔢 A prime number is a number greater than 1 that has no divisors other than 1 and itself. This concept strengthened my understanding of loops, conditional logic, and flag variables in Python. 🧠 What I Learned: 🔹 How to use a flag variable → A flag is like a status indicator that stores a True/False condition. → Example: We assume a number is prime (True) and change the flag if it isn’t. 🔹 How to optimize loops by checking only up to √n 🔹 Logical thinking and condition-based decisions Every line of code teaches something new 💪 On to Day 7 tomorrow! 🚀 #Python #CodingChallenge #50DaysOfPython #ProblemSolving #WomenInTech #LogicBuilding #LearnToCode
To view or add a comment, sign in
-
✨ From “Just Running Code” to “Building Systems” — The Role of File Handling in Python When we start learning Python, we often focus on loops, variables, and functions. But there comes a moment when we want our code to remember something — even after the program stops. That moment is where File Handling changes everything. 📂 It’s not just reading and writing files. It’s about giving your program the ability to: • Store real-world information • Generate logs and reports • Maintain user records • Work with data long-term This is the step where your logic becomes a living application, not just temporary output on the screen. Once you understand file handling, programming stops being “practice”… and starts feeling like creation. 🚀 #Python #FileHandling #ProgrammingMindset #LearnPython #CodeToCreate #TechCommunity #DevelopersJourney #CodingMotivation
To view or add a comment, sign in
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development
Nice work