Where does static variable work in C# page. At Application level or Page Level
- by Shantanu Gupta
I had an interview today and every thing was going very good, but then an interviewer asked me a question Where Does Static Variable Work in C#- At Application Level or At Page Level.
I was not very much clear about this answer as I only knew that static variables are stored on heap and I didn't knew anything about web related thing about it.
Then tried to make me more clear by giving an example that in a page I am using static variable and three users are accessing the page one of the user updates the value of static variable, What value will be visible to remaining two users an old copy or the update will be reflected.