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.
Your method helps to pass all test cases but i don't understand why that works. why n*p>=N works? why are no prime factors for each number considered? how do you arrive at that? I mean I tried everthing else then simply followed the algorithm in your picture but i don't understand at all how it works!
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #69: Totient maximum
You are viewing a single comment's thread. Return to all comments →
Your method helps to pass all test cases but i don't understand why that works. why n*p>=N works? why are no prime factors for each number considered? how do you arrive at that? I mean I tried everthing else then simply followed the algorithm in your picture but i don't understand at all how it works!