Java language provides some basic Atomic operations. These
operations can be used to make sure that concurrent threads always
see the same value.
Some of these Atomic operations are:
1. Read operations on reference variables and primitive
variables (except long and double)
2. Write operations on reference variables and primitive
variables (except long and double)
3. Read operations on all variables declared as volatile
4. Write operations on all variables declared as volatile