fork(1) download
  1. #!/usr/bin/perl -w
  2.  
  3. use strict;
  4.  
  5. chomp(my($x, $n) = <STDIN>);
  6. printf "%b\n", ($x >> $n) | (($x & (~(~0 << $n))) << (63+1-$n));
Success #stdin #stdout 0s 3564KB
stdin
127
3
stdout
11100000000000000000000000001111