Swapping nibbles range style

Volcz volcz at kth.se
Tue Dec 10 14:08:16 PST 2013


Hi!
As a small exercise I've been trying to implement a nibble 
swapping method which utilizes D's ranges.

I received some help from eco on #d but still couldn't complete 
it.
his contribution: http://dpaste.dzfl.pl/f228d0a8

Example:
Input  1234
Output 2143

This is going to be used to build a small utility program which 
can be used "echo 1234 | nibbleswap"

Help is appreciated!


More information about the Digitalmars-d-learn mailing list