English

Class variables ae also known as ______ variables.

Advertisements
Advertisements

Question

Class variables ae also known as ______ variables.

Options

  • publlic

  • instance

  • static

  • default

MCQ
Fill in the Blanks
Advertisements

Solution

Class variables ae also known as static variables.

Explanation:

In Java, class variables are declared using the static keyword. Unlike regular instance variables, a static variable has only one single copy shared across the entire class, meaning all objects created from that class access and change the exact same memory location

shaalaa.com
  Is there an error in this question or solution?
Chapter 6: Encapsulation - Exercises [Page 148]

APPEARS IN

Rupa Pandit Computer Applications [English] Class 10 ICSE
Chapter 6 Encapsulation
Exercises | Q 1. (vi) | Page 148
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×