Consider the following contrived examples-
Say I have a thread that modifies a global variable:
void thread_1() { for (int i=0; i<10; i++) {