.75 each but sold 3 for $2... lets say 4 items
Formula with the numbers replaced would then be:
TotalPrice = (0.75 * 4) - ((3 != "0")?floor(4/3)*0.25:0)
which is equal to:
TotalPrice = 3 - (1 * 0.25)
or TotalPrice = 2.75
The formula is correct. Have you tried it?