implemented singleton, AtomicInteger, synchronised methods