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