A kid had nineteen plastic mugs out of which, all but nine were lost.

How many mugs was he left with?

The phrase "all but nine were lost" means that all his mugs were lost except nine.

Thus he was left with nine mugs.