



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
Coding questions assignment 1 Coding questions assignment 1
Typology: Exams
1 / 5
This page cannot be seen from the preview
Don't miss anything!
PRACTICE PROBLEMS
integer such that the sum of the cubes of its digits is equal to the number itself. Return " Yes " if it is a armstrong number else return " No ". NOTE: 371 is an Armstrong number since 3^3 + 7^3 + 1^3 = 371 Example 1: Input : N = 153 Output: "Yes" Explanation : 153 is an Armstrong number since 1^3 + 5^3 + 3^3 = 153. Hence answer is "Yes".
Input: N = 5, K = 16 Arr[] = {9, 7, 2, 16, 4} Output: 4 Explanation: K = 16 is found in the given array at position 4.
Input: N = 13 , M = 4 Output: 12 Explanation: 12 is the Closest Number to 13 which is divisible by 4.