Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

Re: Using '#' at the beginning of a format?

by Anonymous Monk
on Jan 10, 2013 at 09:27 UTC ( #1012628=note: print w/replies, xml ) Need Help??

in reply to Using '#' at the beginning of a format?

use Perl6::Form
  • Comment on Re: Using '#' at the beginning of a format?

Replies are listed 'Best First'.
Re^2: Using '#' at the beginning of a format?
by Discipulus (Monsignor) on Jan 10, 2013 at 11:31 UTC
    uh uh! never eard of it ... i remember it was better NOT use formats in perl 5. This modules is safe to use?

    there are no rules, there are no thumbs..

      Perl6::Form is a lot better than format. The usage is a lot easier.
      loris request can be done like so:

      use warnings; use strict; use Perl6::Form; my %name_n_price_tag; print form "#\tName\tPrice", "#\t------ -------"; while (<DATA>) { chomp; my ( $name, $price ) = split /:\s/, $_, 2; $name_n_price_tag{$name} = $price; } print form "\t{|||||}\t{|||||}", $_, $name_n_price_tag{$_}, $/ for sort keys %name_n_price_tag; __DATA__ large: 90.12 small: 12.34 medium: 57.78
      # Name Price # ------ ------- large 90.12 medium 57.78 small 12.34
      NOTE however, I don't know how the OP gets it data. This is just a head up using the module Perl6::Form.
      Hope this helps.

      If you tell me, I'll forget.
      If you show me, I'll remember.
      if you involve me, I'll understand.
      --- Author unknown to me

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1012628]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (3)
As of 2018-02-19 19:00 GMT
Find Nodes?
    Voting Booth?
    When it is dark outside I am happiest to see ...

    Results (266 votes). Check out past polls.