---
title: "What is difference between atomic and nonatomic property specifier?"  
description: "What is difference between atomic and nonatomic property specifier?"  
author: "Sunil Singh"  
published: 2015-04-21  
updated: 2020-09-18  
canonical: https://www.mindstick.com/interview/2407/what-is-difference-between-atomic-and-nonatomic-property-specifier  
category: "iphone"  
tags: ["iphone", "ios"]  
reading_time: 1 minute  

---

# What is difference between atomic and nonatomic property specifier?

Atomic means only one thread access the variable but nonatomic means multiple thread access the variable .Atomic is thread safe but nonatomic is thread unsafe.Atomic is fast in performance but nonatomic is slow in performance.Atomic is default behavior but nonatomic is not default behavior . we need to add nonatomic keyword in property attribute. Nonatomic may result in unexpected behavior, when two different process (threads) access the same variable at the same time.

## Answers

### Answer by Sunil Singh

Atomic means only one thread access the variable but nonatomic means multiple thread access the variable .Atomic is thread safe but nonatomic is thread unsafe.Atomic is fast in performance but nonatomic is slow in performance.Atomic is default behavior but nonatomic is not default behavior . we need to add nonatomic keyword in property attribute. Nonatomic may result in unexpected behavior, when two different process (threads) access the same variable at the same time.


---

Original Source: https://www.mindstick.com/interview/2407/what-is-difference-between-atomic-and-nonatomic-property-specifier

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
