Unable to understand how to calculate a, b and c


Can someone please help to know why in the given example a=5,b=6 and c=6


You have to minimize (Max(a,b,c)-Min(a,b,c))
Here a=5, b=6 and c=6 so Max(a,b,c)= 6 and Min(a,b,c)=5
6-5=1 and no other triplet can minimize the difference further hence we take 6,5,5 triplet as the solution and return 1