What is a class variable?

By AMAN SINGH in 7 Sep 2023 | 11:37 am
AMAN SINGH

AMAN SINGH

Student
Posts: 34
Likes: 1
Member since: 6 Sep 2023

What is a class variable?

7 Sep 2023 | 11:37 am
0 Likes
Prince Chauhan

Prince Chauhan

Student
Posts: 68
Likes: 2
Member since: 6 Sep 2023

A class variable is a variable that is defined in a class and shared by all instances of the class. Class variables can be used to store information about an object, such as its name, its location in memory, and its state at any given time. Class variables are often used to store information that is shared by objects in the same class. For example, a class might have a variable called name that is shared by all instances of the class. Class variables are often created with the special keyword class

7 Sep 2023 | 11:37 am
0 Likes

Report

Please describe about the report short and clearly.