Placement AptitudeVery hardCAT · Infosys
How many of the integers 1, 2, …, 100 can be written as x² − y² with x and y non-negative integers?
- A. 50
- B. 25
- C. 75
- D. 100
Correct answer: C. 75
x² − y² = (x − y)(x + y), and the two factors have the same parity, so the result is odd or a multiple of 4; every such n works (odd n = 2k + 1 = (k+1)² − k², 4m = (m+1)² − (m−1)²). Only numbers of the form 4k + 2 fail: 25 of them, leaving 75. 50 counts only odd numbers.
Practise more Permutations, Combinations and Probability (Placement) questionsPermutations, Combinations and Probability (Placement): notes and key points
More Permutations, Combinations and Probability (Placement) questions
- Seven points lie on one straight line and five on another line parallel to it. How many triangles have their vertices among these 12 points?
- How many rectangles of area exactly 8 square units, with sides along the grid lines, are there on an 8 × 8 chessboard?
- How many 4-digit numbers (1000 to 9999) use exactly two different digits, such as 3383 or 7000?
- A number from 1 to 100 is chosen at random, and it turns out not to be divisible by 5. What is the probability that it is divisible by 2…
- Two players each roll a fair die; the higher number wins, and on a tie both roll again. What is the expected number of rounds needed to…
- A point is chosen at random inside a square of side 2 units. What is the probability that it lies within 1 unit of the centre of the square?