Re: Data Conversion ?

[email protected] ("John W. Krahn") Fri, 06 Nov 2009 18:02:49 -0800
Newsgroups perl.beginners.cgi
Message-ID <[email protected]>
Nathan Gibbs wrote:
> How would I get the length of a string as returned by length () into
> 
> a 4 byte unsigned integer in  network byte order

my $length = pack 'N', length $string;



John
-- 
The programmer is fighting against the two most
destructive forces in the universe: entropy and
human stupidity.               -- Damian Conway