HTML
CSS
PHP
Deno
Examples
Do It Yourself
Blog
Type in your code below
Run
<?php //made buyer's amount and item price of the same value $buyer_amount = 90; //The item price $item_price = 90; if ($buyer_amount < $item_price) { echo "You do not have sufficient funds to purchase this item"; } else if($buyer_amount === $item_price){ echo "You have no change"; } else { echo 'You have successfully purchase this item, your change is '. ($buyer_amount - $item_price).''; } ?>