Menu
Question Index
...

What will be the output of the following program?

public class Character Demo {
    public static void main(String[] args) {
        int num = 3;
        int num2 = 16;
        char ch = Character.forDigit(num, 10);
        char ch1 = Character.forDigit(num2, 36);
        System.out.print(ch + ", " + ch1);
    }
}


10, g
3, e
3, g
Some other output
Compilation Error or Runtime Error

Doubts

Problems

Topic: Java Character Class

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App