#!/bin/perl # Similar to vatwhile.pl but reads data from a file $vat = 17.5; print "VAT Amount Entered\n"; while ($amount = ) { $Vat = ( $amount - ($amount * 100 / (100 + $vat))); printf("%-6.2f %-6.2f\n", $Vat, $amount); }