Why we not able to instantiate Math class in java..?? | Sololearn: Learn to code for FREE!
Nouvelle formation ! Tous les codeurs devraient apprendre l'IA générative !
Essayez une leçon gratuite
+ 2

Why we not able to instantiate Math class in java..??

22nd Nov 2017, 10:25 AM
Ajay Gaikwad
Ajay Gaikwad - avatar
2 Réponses
+ 4
You can not create an object of Math class because the constructor of Math class has a private modifier.
22nd Nov 2017, 11:12 AM
Md. Nafis Ul Haque Shifat
Md. Nafis Ul Haque Shifat - avatar
0
becous its constructor has private method
6th Jan 2018, 12:49 PM
Eslam Faisal
Eslam Faisal - avatar