find charecter from its ascii value.

how could find charecter from its ascii value.
please suggest me any code for that.
thannks in advance.

You can use perl's pack function to do that

$hex_ascii=%20;
print "HEX $hex_ascii\n";
$hex_ascii =~ s/%(..)/pack("c",hex($1))/ge;
print "Alpha $hex_ascii\n";

Code above may not suit exactly what you're looking for, but hopefully points in the right direction :slight_smile:

, Mike

You can convert back and forth in a shell script with printf and od. For example a lower case "a" = octal 141...

$ printf a | od -An -to1
         141
$ printf "\141 \n"
a
$