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