#!/usr/bin/perl use strict; print "Enter a character or a word: "; chomp($_=); print "$_->[1]: $_->[0]\n" for map{[unpack("B*",$_),$_]}split'';