A person forgets his 4-digit ATM pin code. But he remembers that in the code all the digits are different, the greatest digit is 7 and the sum of the first two digits is equal to the sum of the last two digits.Then the maximum number of trials necessary to obtain the correct code is _____ . [2023]
(72)

Sum of first two digits
Sum of last two digits =
Case–I : = 7
2 × 12 = 24 ways.

2 × 8 ways = 16 ways

2 × 4 ways = 8 ways
Total ways = 24 + 16 + 16 + 8 + 8 = 72