I am assuming there are more than one juice box in a package so if the amount of juice boxes in each package is X and there are four packages 4X.
So 4X - 2= Answer
If we make it so that there are 6 juice boxes in each package and use the same method this is what we'll get:
24 - 2= 22
22 would be the juice boxes left over.
I hope this answers your question, if it doesn't use the same method with the number of juice boxes in a package.