Thank you very much for your answer. Now I read the whole tutorial perlpacktut. And I did many experiments with pack/unpack. And now I know the behaviour of "N". If you use "N" with unpack and in memory is less than 4 bytes then nothing is unpacked. "N" with unpack is only unpacking something if there are at least 4 bytes in memory left. So you were totally right. Adding "\0\0\0" to the string will always work.
Because the pack tutorial was so interesting I still did not read the perlsub tutorial. But this will come next. Because you are right. At the moment I don't know the difference between calling a function with & or without, ...
Greetings,
DirkIn reply to Re^6: CRC of a string
by Dirk80
in thread CRC of a string
by Dirk80
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |