Computer Science, asked by fffghhgf, 1 day ago

Write a statement in Java, to declare a constant MAX and store the value 100 in it​

Answers

Answered by purveshKolhe
2

\huge{\red{\boxed{\mathfrak{\green{ answer : }}}}}}

Full Co de::

class Demo{

public static void main(String [] args) {

final int MAX = 100;

}

}

==> We used final access modifier which means we cannot change the value of the variable and if we try to do so, it will generate an error.

I hope that my answer helps you...

Similar questions