🤔 Time for another coding puzzle:
What’s the output of this Java code snippet?
String str1 = new String("Hello");
String str2 = new String("Hello");
System.out.println(str1 == str2);
Share your insights,Java wizards!👨💻🔍 #JavaQuestion#CodingPuzzle#JavaProgramming#JavaBasics
Note: The constructor of a class cannot access static property of the class. So do a class have a seperate state and its object have a seperate state?
#Java#JavaQuestion
But if we take C++ we can write the functions inside as well as outside the class ,so in C++ they are called member functions or an object
#important#softwareengineer#javaquestion#oops