11
Jiří Trnka
Last seen 24 days ago
Member for 8 years, 17 days
Difficulty Normal
Thanks for this solution. It helped me to learn or understand better some Python techniques. And not to forget, I like your way of thinking :-)
More
Nice solution. It took me a while before I figure out that the rank Counter object is used to impose a (partial) ordering in the graph components. I think it would work also if you use just direct comparing of the nod values = names as strings (i.e. _xr < yr_
instead of _rank[xr] < rank[yr]_ and _r
More
Excellent solution, mainly the idea to employ the binary search to reduce complexity. My first shot was counting the values sequentially, then just changed it to recurrent formula. But that's a whole nuther story regarding complexity :-)
I like also the way you can get any number by adding some powe
More