Day 9 #100daysofpython update, solved the problem🥳
setA->input for n other sets->dynamically created other set and store in sets[]->if setA>=i in sets[]->store i in sets2->if sets==sets2-> print True.
Any suggestions on making it cleaner?🧠
Day8 #100daysofpython🐍Today I solved a 3D coordinate system problem using OOP. Revised vectors, unpacking operator* and learned Mathematical function pow(base, exponent). Slowly building stronger fundamentals.🧠#hackerrank#codingJourney
Day7 #100daysofpython🐍 today I realised coding is less about syntax and more about thinking in system.
Improving and extending the previous uber🚗 system logic. List of passengers->list of drivers->use of loops for assigning driver and fare for each passenger.
DAY6 #100daysofpython
learnt OOPs made this from scratch.
learnt about:
nonetype errors
wrong function calls
map misuse
input parsing
attribute vs method confusion. #CodingJourney#BuildInPublic
Day 5 of #100DaysOfPython 🐍
Tried → failed → tried again → finally worked.
Today's takeaways:
• Using the unpacking operator * with variables
• Formatting output with f-strings to show values up to 2 decimal places
Always open to suggestions for writing cleaner code!
Day4 🐍 Got stuck for hours figuring out how to get all students with the second lowest marks. I had the logic but struggled with execution.
Today's takeaway: First try applying previous concepts> I didn’t use list comprehension in my first attempt.👾
Day4 🐍 Got stuck for hours figuring out how to get all students with the second lowest marks. I had the logic but struggled with execution.
Today's takeaway: First try applying previous concepts> I didn’t use list comprehension in my first attempt.👾
Day3 of #100daysofpython🐍
Today's takeaways:
—> map(function, iterable) - returns a map object
—>sets and methods in sets{collection of unordered data items, do not allow duplicate items } and set() function
—>list comprehension can replace loops and map() functions.#hackerrank
After hours of brainstorming, cracked the solution!💡
Where did I go wrong?
Created a "s variable" instead I could have just performed sum operation I+j+k to eliminate.
#onestepaday
Day 2 of #100daysofpython🐍
Tried solving a list comprehension problem.First created all coordinates, then got stuck figuring out how to compute (i + j + k) with conditions.
Tried using loops first to understand the logic.
How long did it take you to master list comprehension?
Day 2 of #100daysofpython🐍
Tried solving a list comprehension problem.First created all coordinates, then got stuck figuring out how to compute (i + j + k) with conditions.
Tried using loops first to understand the logic.
How long did it take you to master list comprehension?
What went wrong?
For instance:1900 → divisible by 4 → returns True, but it’s also divisible by 100
1900 is not a leap year.
Years divisible by 100 are fewer than years divisible by 4, and years divisible by 400 even fewer.
First,check for rare cases then for generic cases.
Day 1 of #100daysofpython🐍
Task-->Check whether a year is leap year or not.
return True if it is, else return False.
....
But it failed for some test cases.
#beginner#hackerrank
Day 1 of #100daysofpython🐍
Task-->Check whether a year is leap year or not.
return True if it is, else return False.
....
But it failed for some test cases.
#beginner#hackerrank