Domanda di colloquio di Prestige Group

What is the difference between weak and strong in iOS memory management?

Risposta di colloquio

Anonimo

5 dic 2023

This question assesses your understanding of memory management in iOS using ARC (Automatic Reference Counting). A strong reference increases the reference count of an object, while a weak reference does not. Weak references are often used to avoid strong reference cycles (retain cycles) and prevent memory leaks.