in reply to Re^7: Binary to decimal conversion
in thread Binary to decimal conversion
Said code (and then some):
$\ = "\n"; print(my @a = reverse('hello')); # hello (order or scalars reversed) print(my $s = reverse('hello')); # olleh (order of chars reversed) print(reverse('hello')); # hello (order or scalars reversed) print(scalar(reverse('hello'))); # olleh (order of chars reversed) sub f(@) { return @_; } sub g($) { return @_; } print(f(reverse('hello')); # hello (order or scalars reversed) print(g(reverse('hello'))); # olleh (order of chars reversed)
In Section
Seekers of Perl Wisdom