Two typical methods to find all divisors are given. You can also get the implementation examples. Use as a reference (^_^)/
We sometimes need to find GCD and LCM for competitive programming. This time I summarized how to write...
We sometimes need to convert decimal numbers to the k-decimal ones. For example, in the...
BFS (Breadth-First Search) is one of the popular ways to search all of the vertices on a given graph. I write this article to understand well.
An expected value of the number of trials with probability p is calculated. It's not so hard to see why but for my understanding I tried to calculate it.
This time I introduce Floyd-Warshall algorithm that finds the minimum distance between all vertex pairs with O(V^3) complexity. Read this!