Online Java Compiler By
JavaTpoint.com
import java.util.concurrent.atomic.AtomicInteger; public class AtomicIntegerGetAndAddExp5 { public static void main(String[] args) { AtomicInteger number = new AtomicInteger(20); number.getAndAdd(0); System.out.println("Updated number is: " + number); } }
Output