NO input format and Constraints displayed

Give me some constraints; my answer is showing time imit off

Solve it mathematically on paper and get the answer.
Write O(1) time solution :slight_smile: