You gain profit is when you sell your product for more than the cost price. You made a loss if you sell your product for less than the cost price. To calculate the percentage of profit/loss you need to divide the profit/loss by the cost price and then times by 100. e.g 5/22 x 100 = 22.7%
Hey today I bought a chocolate bar for 32c and sold it for 50c!
Fantastic! If you divide the 18c by the cost you bought your chocolate for and then times by 100 that means you made a 56.25% profit! Good Job!