मराठी

Consider the following class: public class MyClass { public static int x - 3, y = 4; public int a = 2, b = 3; } Name the variables for which each object of the class will have its own distinct copy. - Computer Applications

Advertisements
Advertisements

प्रश्न

Consider the following class: 

public class MyClass 
{ 
public static int x - 3, y = 4; 
public int a = 2, b = 3; 
}
  1. Name the variables for which each object of the class will have its own distinct copy.
  2. Name the variables that are common to all objects of the class.
लघु उत्तर

उत्तर

  1. The variables for which each object of the class will have its own distinct copy are a and b.
  2. The variables that are common to all the objects of the class are x and y. 
shaalaa.com
  या प्रश्नात किंवा उत्तरात काही त्रुटी आहे का?
पाठ 6: Class as the Basis of all Computation (Objects and Classes) - Review Insight [पृष्ठ ३८१]

APPEARS IN

अविचल Computer Applications [English] Class 10 ICSE
पाठ 6 Class as the Basis of all Computation (Objects and Classes)
Review Insight | Q 9. | पृष्ठ ३८१
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×