Suppose you have the following statements in your program wi
Suppose you have the following statements in your program, will it pass compilation without any error? If an error is showing during the compilation, write down the correct statement is The name of the fixing process name it in word. double speed = 75.5; int points = speed; You are trying to compare two primitive variables, what comparison symbol you should use? You are trying to compare two java objects for its content, what is the method name you should use You are designing a class with several private instance variables, can these variables be accessed by methods outside of the class definition? If you try to read the value of a private instance variable outside of the class, what kind of method you should use? ANS (1): circle YEs or No ANS(2):
Solution
5. ans1. there will be a compilation error. lossy conversion. therefore the
ans2. int points=(int)speed;
ans3. type casting
6. ans1. == is the symbol
ans2. equals() method will be used to compare two java objects.
7. ans1. yes the data can be accessed outside indirectly.
ans2. Accessers
for further queries kindly get back.
