Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: Easy hash question (uninitialized value)

by marto (Archbishop)
on May 16, 2018 at 10:55 UTC ( #1214636=note: print w/replies, xml ) Need Help??


in reply to Easy hash question (uninitialized value)

Use chomp:

.... say 'Enter a number: '; my $number = <STDIN>; chomp( $number ); say $number; ....

Produces:

Enter a number: 4 4 bash done

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1214636]
Considered: [marto]: reap: unintended duplicate of Re: Easy hash question (uninitialized value).
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (4)
As of 2018-05-23 03:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?