Using oct function to convert number to octal numbers : oct « Data Type « Perl






Using oct function to convert number to octal numbers

   

#!/usr/bin/perl -w

print oct("030"), "\n";

   
    
    
  








Related examples in the same category

1.Convert a number with the hex() or oct()
2.Illegal octal number: with 8 inside
3.Octal number
4.Octal numerals starting with 0x
5.oct("178")
6.octal data
7.Reads any kind of integer.