STATIC KEYWORD
What is a static variable and what is the use of static keyword...?
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend4days leftRegister
Satyapriya NayakRank #47 · 31.5K reputationPosted May 19, 2013, 10:46 PM EDT
Sandeep Singh ShekhawatRank #147 · 15.6K reputationPosted May 19, 2013, 10:47 PM EDT
Static variable are those variable that has a fix value for application and can assign by using static constructor and call by class name.
Static keyword denots that these variable intilized when any variable or method of class will call then all variable will be initilized and initilize only single time no matter what we call.
- A constant or type declaration is implicitly a static member.
2. A static member cannot be referenced through an instance. Instead, it is referenced through the type name.