IHYPRESS.NET > PERL
HOME
|
ASP
|
C
|
HTML/CSS
|
JAVASCRIPT
|
MATLAB
|
PERL
|
PHP
|
PYTHON
|
RUBY
Home
> Program #15 [Formatted Output]
CODE
RESULT
<
#!/usr/bin/perl use CGI ':standard'; print "Content-type: text/html\n\n"; $price = 19.99; printf ("%8.4f
", $price); $p = sprintf ("%8.7f
", $price); print $p; printf ("%8.1f
", $price); printf ("%8.0f
", $price);
>
COPYRIGHT © 2019 IHYPRESS.NET. A DIVISION OF IHY PRESS, KIRKLAND, WA 98083 USA. ALL RIGHTS RESERVED.
SHARE