Algorithm: * Start * To input the lower limit * To input the upper limit * To run the outer loop * To run inner loop * To calculate total number of prime numbers between lower and upper limits * To declare array with it’s number of elements as ‘s’ * To run the outer loop * To run the inner loop * To store the prime numbers in array a[] * To run a loop for every position of array a[] * If condition matches for the number for prime triplets * Continue till all Prime Triplets are printed
Question 2: A unique digit integer is a positive integer (without leading zeros) with no duplicate digits. For example 7, 135, 214 are all unique digit integers whereas 33, 3121, 300 are not. Given two positive integers m and n, where m<n, write a program to determine how many unique digit integers are there in the range between m and n (both inclusive) and output them.
Algorithm: * Start * To input the starting limit * To input the last limit * To run the outer loop * To store the value of ‘i’ as a string * To run the inner loop * To run a nested loop of the inner loop * To check for repetition of any digit in the number * To store all the unique digit integers in a string * To store the frequency of unique digit integers * To print the unique digit integers and their frequency
Question 3: Write a program which inputs Natural numbers N and M followed by integer arrays A[ ] and B[ ], each consisting of N and M numbers of elements respectively. Sort the arrays A[ ] and B[ ] in Ascending order of magnitude. Use the sorted arrays A[ ]