Question
What is the use of Volatile Keyword?
Answer
Volatile is a declaration that a variable can be accessed by multiple threads and hence shouldn’t be cached.
What is the use of Volatile Keyword?
Volatile is a declaration that a variable can be accessed by multiple threads and hence shouldn’t be cached.