We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Reduce Function
Reduce Function
Sort by
recency
|
210 Discussions
|
Please Login in order to post a comment
Here is HackerRank Reduce Function in Python solution - https://programmingoneonone.com/hackerrank-reduce-function-solution-in-python.html
This is easy one and simple logic! The one fraction value in fracs is passed to x and another passed to y. Then it will multiplied and remaining also multiplied with answer. now we get multiplication of fraction. This value is reduced using reduce() to find numerator and denominator