sub print_length { my ($s) = @_; print(length($s), "\n"); } my $s = "\x{100}"; print_length($s); # 1 { use bytes; print_length($s); # 1 print(length($s), "\n"); # 2 } print_length($s); # 1
In reply to Re^3: Another use bytes and length issue
by ikegami
in thread Another use bytes and length issue
by zubster
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |