Given a positive integer N, find out whether N is a tetracontagonal number (also called a tetracontagon number): one of the numbers produced by 40-sided polygons. What is a tetracontagonal number? Polygonal Read more →
Algorithms
6 postsGiven the Numerator and Denominator of N Rational Numbers, the task is to find the maximum Rational Number from the array. Examples: Input: N = 2 num[] = { 3, 3 } Read more →
Given an integer N, the task is to check if it is a pentacontagon number or not. Pentacontagon number is class of figurate number. It has 50 – sided polygon called pentacontagon. Read more →
Given an integer N, the task is to check if it is a Triacontakaidigon number or not. Triacontakaidigon number is class of figurate number. It has 32 – sided polygon called Triacontakaidigon. Read more →
Given an integer N, the task is to check if it is a hexacontagon number or not. Hexacontagon number is class of figurate number. It has 60 – sided polygon called hexacontagon. Read more →
Given an integer array and a positive integer k, count all distinct pairs with product equal to k. Examples: Input: arr[] = {2, 6, 4, 3, 1}, k = 12 Output: Count Read more →
Given a number N, the task is to check if N is a dodecahedral Number – Dodecahedral Number belongs to a figurate number and represents it dodecahedron. The first few dodecahedral numbers Read more →
Given a positive integers N, the task is to find the smallest N digit number divisible by N. Examples: Input: N = 4 Output: 1000 Explanation: 1000 is the smallest 4-digit number Read more →
Given an array arr[] of integer elements, the task is to find the length of the largest sub-array of arr[] such that all the elements of the sub-array are Fibonacci numbers. Examples: Read more →
Given an array containing n numbers. The problem is to find the length of the longest zigZag subarray such that every element in the subarray should be in form a < b Read more →