perldoc -f length #!/usr/bin/perl -w use strict;
my $num=123; my $match=length($num); print "$match\n"; # should print 3 __END__ José. > -----Original Message----- > From: David Gilden [mailto:[EMAIL PROTECTED] > Sent: Wednesday, March 12, 2003 5:09 PM > To: [EMAIL PROTECTED] > Subject: getting the number of characters > > > Hello, > > I am looking for the $num to treated as a string and get the > number of characters, in this case I am look for 3 to be returned. > > Later I want to use this number to pad a string with > zeros.... Thanks! Dave > > #!/usr/bin/perl -w > > $num =123; > > ($match) = ($num =~ m/(\d)/); > > > print "$match \n"; # should print 3 > > __END__ > > ============================================== > Cora Connection: Your West African Music Source > Resources, Recordings, Instruments & More! > <http://www.coraconnection.com/> > ============================================== > > -- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > **** DISCLAIMER **** "This e-mail and any attachment thereto may contain information which is confidential and/or protected by intellectual property rights and are intended for the sole use of the recipient(s) named above. Any use of the information contained herein (including, but not limited to, total or partial reproduction, communication or distribution in any form) by other persons than the designated recipient(s) is prohibited. If you have received this e-mail in error, please notify the sender either by telephone or by e-mail and delete the material from any computer". Thank you for your cooperation. For further information about Proximus mobile phone services please see our website at http://www.proximus.be or refer to any Proximus agent. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]