Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: 1 vs "1"

by riffraff (Pilgrim)
on Sep 13, 2001 at 00:27 UTC ( #112012=note: print w/replies, xml ) Need Help??


in reply to 1 vs "1"

You could also force the string to be looked at as a string, by, for example, prepending a character in front of it:

$a=1; func($a); # a number func("x$a"); # now a string

riffraff

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://112012]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (8)
As of 2022-08-10 11:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?