Exact difference between strong and weak property in ios…and if ARC is there then why to use strong


This question already has an answer here:

<ul><li> <a href="/questions/8927727/objective-c-arc-strong-vs-retain-and-weak-vs-assign" dir="ltr" rel="nofollow">Objective-C ARC: strong vs retain and weak vs assign</a> <span class="question-originals-answer-count"> 8 answers </span> </li> </ul>

What is Exact difference between strong and weak property in ios and if ARC is there then why to use strong instead of retain and weak instead of assign?


You should look a little bit more in the internet for that question. It is a very common one you should find an answer easily.

Basically strong property are retained and weak are not. For an object you should use weak instead of assign because when released the weak property will be set to nil (not the assign). Keep assign for basic type (int, float, etc.) In ARC strong is defined as retain.

Most of the time: - for object property (array, dictionnary, etc.) use strong. - for delegates use weak. - for basic type (int, float, etc.) use assign.

You will find more detailed answers all over the internet.


  • How to read JSON-LD data from HTML in Objective-C?
  • How to remove left and right margins from all wrapped rows in flexbox (without nth-child or js)
  • Android application not restoring state when installed from .apk, works fine from eclipse
  • JavaScriptCore External Arrays
  • Application bar icon text length
  • Less Conflicting Session Manager for Zope 2
  • Python cosine function precision [duplicate]
  • HttpClient: disabling chunked encoding
  • Facebook iOS SDK Not Calling Completion Handler
  • how to set variables in a php include file?
  • Trying to get the char code of ENTER key
  • Java color detection
  • nonblocking BIO_do_connect blocked when there is no internet connected
  • Jenkins: FATAL: Could not initialize class hudson.util.ProcessTree$UnixReflection
  • Does Mobilefirst provide a provision to access web services directly?
  • Problems installing Yesod for Haskell
  • zope_i18n_compile_mo_files doesn't work on a Zeo configuration
  • OOP Javascript - Is “get property” method necessary?
  • Marklogic : Query response time is very high
  • How to define and use opencv mat of user type
  • Custom Tabgroup Appcelerator
  • Allowing both email and username for authentication
  • Database structure design with variable amounts of fields
  • Extracting HTML between tags
  • Scrapy recursive link crawler
  • Get one-time binding to work for ng-if
  • Installing Hadoop, Java Exception about illegal characters at index 7?
  • Different response to non-authenticated users and AJAX calls
  • How do I fake an specific browser client when using Java's Net library?
  • JavaScriptCore crash on iOS9
  • How to get a value (ex: baseURL) in every Karate feature?
  • vba code to select only visible cells in specific column except heading
  • How do you troubleshoot character encoding problems?
  • QuartzCore.framework for Mono Develop
  • How can I remove ASP.NET Designer.cs files?
  • python draw pie shapes with colour filled
  • Is there any way to bind data to data.frame by some index?
  • Checking variable from a different class in C#
  • Django query for large number of relationships
  • How can i traverse a binary tree from right to left in java?