Maths Trick Question: Ahmad Is A Poor Man

Ahmad is a poor man. He has no money.

He wants to buy a shirt that cost $50.00

He borrows from his friend, A, $25.00

He borrows from his friend, B, $25.00

He goes to the shop to buy the shirt.

The shirt is on sale. Now, it costs only $45.00

He pays for the shirt and gets a $5.00 in change.

He pays back his friend, A, $1.00

He pays back his friend, B, $1.00

Now he has $3.00 in his pocket.

He owes his friend, A, $24.00

He owes his friend, B, $24.00

So, he owes $48.00 in total.

He still has $3.00

$48.00 + $3.00 = $51.00

How can there be $51.00 when he only borrowed $50.00?

Try to explain this!