Using fork join_none to span threads in a for loop in parallel, which is executed in forever loop

In reply to VarshaAnand2402:

thread is not killed. It will go to infinite value if you remove it, because abc=a will be immediately executes and it will run forever.
by adding abc!=a, I am letting this thread wait till changed and get the same value again.