← All problemsSign in

Vamsi and holy Numbers

Vamsi called a number holy if it follows following two rules. 1. Number is a prime number2. Sum of all the digits in binary conversion of the number isn't prime For example 2 is a holy number as it is a prime number and also sum of the digits in its binary conversion (10)2 is 1 which is not a prime number Vamsi challenged his friend Aman to calculate sum of all such holy numbers occurring between

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start