Online Java Compiler By
JavaTpoint.com
public class IntegerValueOfExample3 { public static void main(String[] args)throws NumberFormatException { String strValue = "234"; System.out.print("Desired Value is: "+strValue); int radix = 8; System.out.print("\nBase Number is: "+radix); // print the value in decimal format System.out.println("\nInteger Value: " + Integer.valueOf(strValue, radix)); } }
Output