0
Java Output
Hi im A learner wants to learn and take notes on challenge questions guess at least 5 a day if its okay to you guys can you guys explain to me what happens to this code?need a clearer insight.tnx in advance😀 https://code.sololearn.com/cLxsiWaH3hf9/?ref=app
2 Antworten
+ 2
Classes c and c2 are being created by name. Now, notice that the name Simple refers to a class and the name My to an interface: lines 1 and 3.
So on line 8 c.isInterface() returns false because c was built using the name Simple and Simple refers to classes.
Line 10 returns true because c2 is indeed an interface because of the way it was created on line 9
+ 1
Thank you!noted🎯