🚀 Sieve of Eratosthenes in Java
Find all prime numbers up to n efficiently by:
✔️ Marking every number as prime initially
✔️ Iteratively eliminating multiples of each prime
✔️ Printing the numbers that remain marked
🚗🏍️ Practicing Inheritance in Java OOP today!
Built a simple Transport System:
🔹 Vehicle → Base class
🔹 Car → Inherits Vehicle + AC functionality
🔹 Motorcycle → Inherits Vehicle + Wheelie functionality
Used a Main class for printing outputs
Just practiced Encapsulation in Java 🔒
Created a Student class with private fields, constructors, getters, and setters. Also added validation to prevent invalid age values.
It's amazing how OOP helps keep code clean, secure, and maintainable! 💡
#Java#OOP#Coding#Programming
Implemented a Prime Number Generator in Java that prints all prime numbers from 0 to a user-defined limit.
Key concepts used:
• Functions/Methods
• Iteration with loops
• Prime number checking logic
• Object creation and method calls
Consistency > Complexity. Keep building.
Today's Java practice 💻
Created a Perfect Number Checker that:
✔️ Finds all divisors
✔️ Calculates their sum
✔️ Determines whether the number is perfect
Small projects like these help strengthen problem-solving and logic-building skills.
#Java#CodingJourney#Programming
Today's coding practice ✅
Implemented an Armstrong Number checker in Java from scratch, without using `Math.pow()`. Learned a lot about loops, digit operations, and problem-solving along the way.
Small steps, consistent progress! 🚀
#Java#CodingJourney#Programming#Developer
🚀 Learned how to find the Greatest Common Divisor (GCD/HCF) in Java today! It was a great exercise in understanding problem-solving, loops, and algorithmic thinking. One step closer to becoming a better developer. 💻✨
#Java#Programming#CodingJourney#LearnToCode