Question : CAT Pairs Tim while preparing for his CAT exam, was studying the topic Number Systems. He encountered a following difficult question: Given a number N, find the number of pairs (x,y) where both x and y are less than N and Highest Common Factor (HCF) of x and y is 1.
Answers
Answered by
0
Answer:
hi
Step-by-step explanation:
mark my barin list please
Answered by
0
Answer:
Note: 0 can be included within the pairs
Input Specification:
Input: The number N from which the pairs (x,y) should be obtained
Output Specification:
Return the total number of pairs
input1: 4
Output: 9
Step-by-step explanation:
The pairs can be (1,0) ,(0,1) (1,1) (1,2) (2,1) (0, 3) (3,1) (2,3) (0,2)
So, a total of 9 pairs
Similar questions