#!/usr/bin/env perl use utf8; ############################################################################### # This program reads bytes from STDIN and prints them in decimal format. # # Copyright © 2020 Richard Lesh. All rights reserved. ############################################################################### use Utils; use strict; use warnings; MAIN: { binmode(STDIN); my $c; my $count = 0; while (defined($c = Utils::getbyte(*STDIN))) { print $c, " "; ++$count; if ($count % 20 == 0) { print "\n"; } } if ($count % 20 != 0) { print "\n"; } }