MODULO MATH (Difficult)
CodeChefOpen on judge ↗
Given a number $N$. Find the numbers divisible by $N modulo 10$ or $N modulo 7$ upto $N - 1$. From the list of those numbers, find two numbers $L$ and $S$, one of them $L$ is just smaller than the largest number and the second number $S$ is just larger than the smallest number. Find the average $A$, of $L$ and $S$. Display a number $G$ which is $N modulo A$. ###Category: - Difficult (60 Marks
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start