Pergunta de entrevista da empresa Luxoft

Should synchronized be used when used with atomic operation, say setting and getting values of integer?

Resposta da entrevista

Sigiloso

9 de abr. de 2010

Yes, as synchronized keyword makes sure that value of the variable is updated for every thread, even though operation is atomic

4