(a)
bool: ispacked(string[])
return bool: (string[0] > charmax);
(b)
strlen(string[])
{
new len = 0;
if (ispacked(string))
while (string{len} ! '^0') /* get character from pack */
++len;
else
while (string[len] ! = '^0') /* get cell */
++len;
return len;
}