Skip to content
We areTOP 1%

Deleting Divisors

MediumRating 1700CodeforcesMixed Practice
Solve on Codeforces(opens in a new tab)
Track your progress
First attempt
Re-solve after a few days
Final pass before interviews
Approach hintTry it first, then reveal

Tabulate small values first: odd numbers turn out to be losing, and an even number that is not a power of two can always move to an odd one. Powers of two need separate care, since only halving is worth considering.

More in Mixed Practice

Mixed Practice questions
#ProblemPlatformDifficultyOpen1st1st Visit2nd2nd VisitRevRevise
1Deleting DivisorsCodeforcesMedium 1700Solve Deleting Divisors on Codeforces (opens in a new tab)
2Enlarge GCDCodeforcesHard 1800Solve Enlarge GCD on Codeforces (opens in a new tab)
3Beautiful NumbersCodeforcesHard 1800Solve Beautiful Numbers on Codeforces (opens in a new tab)
4Kth Smallest InstructionsLeetCodeHard Solve Kth Smallest Instructions on LeetCode (opens in a new tab)
5Shichikuji and Power GridCodeforcesHard 1900Solve Shichikuji and Power Grid on Codeforces (opens in a new tab)
6Palindrome Game (hard version)CodeforcesHard 1900Solve Palindrome Game (hard version) on Codeforces (opens in a new tab)
7Reaching PointsLeetCodeHard Solve Reaching Points on LeetCode (opens in a new tab)
8Compress WordsCodeforcesHard 2000Solve Compress Words on Codeforces (opens in a new tab)
9Wish I Knew How to SortCodeforcesHard 2000Solve Wish I Knew How to Sort on Codeforces (opens in a new tab)
10Directing EdgesCodeforcesHard 2000Solve Directing Edges on Codeforces (opens in a new tab)
11Propagating treeCodeforcesHard 2000Solve Propagating tree on Codeforces (opens in a new tab)
12Circular RMQCodeforcesHard 2200Solve Circular RMQ on Codeforces (opens in a new tab)

Sign in to track your progress

Your checkboxes, streak and activity heatmap are saved to your account and sync across devices. It is free.
Sign in with email

New here? Create an account