The correct option is C 24
The base of the cuboid is a square. Hence, the two of the sides of the cuboid are equal. Let the sides of the cuboid be given by (a,a,b), where b is the height when the base is the square.
Sum of all edges =8a+4b
Sum of areas of all faces =2a2+4ab
Both are equal
⇒8a+4b=2a2+4ab
⇒4a+2b=a2+2ab
⇒a2−4a+2ab−2b=0
⇒(a−2)2+2ab−2b−4=0 (eqn 1)
(a−b)2≥0⇒2ab−2b−4≤0
⇒b(a−1)≤2
Now, keeping in mind a≥1 and b≥1(both being integers), the only possibe solutions to the above equation are a=3,b=1 or a=2,b=2.
a=3,b=1 doesn't satisfy eqn 1 while a=2,b=2 does.
So, sum of all its edges =24