Help for this page
When unpacking, A strips trailing whitespace and nulls,
Z strips everything from the first null to the end,
and a returns data with no stripping at all.
$b = pack("Z*C", "test", 10)
($str, $byte) = unpack("Z*C", $b);
When unpacking, a grabs everything and returns unchanged,
A grabs everything but strips from first null to the end
and trailing spaces.
Z stops after first null, the null is stripped from data.
www.com | www.net | www.org
Results (99 votes). Check out past polls.