Solved LeetCode problem 728: Self Dividing Numbers with Python

🗓 Day 4 / 100 – #100DaysOfLeetCode 📌 Problem 728: Self Dividing Numbers The task was to find all numbers in a given range that are self-dividing — i.e., numbers that are divisible by each of their digits and contain no zero. 🧠 My Approach: Iterated through the range of numbers. Checked each digit of a number to ensure: It’s non-zero. The original number is divisible by that digit. Collected all numbers that satisfied both conditions. ⏱ Time Complexity: O(n × d) — where d is the number of digits in each number. 💾 Space Complexity: O(1) 💡 Key Learning: This problem strengthened my understanding of digit-wise iteration and conditional logic — simple concepts that are essential for handling number-based and math-intensive problems efficiently. Small problems like these build the habit of writing clean, readable, and logical code — one step closer each day 🚀 #100DaysOfLeetCode #LeetCodeChallenge #Python #ProblemSolving #LogicBuilding #Programming #DataStructures #Algorithms #DSA #CodingJourney #CodingChallenge #CodeEveryday #LearningInPublic #CompetitiveProgramming #DeveloperJourney #TechStudent #CareerGrowth #CodingCommunity #KeepLearning

  • No alternative text description for this image

To view or add a comment, sign in

Explore content categories