Introduction
Null safety helps avoid errors by making sure collections handle null values safely.
When you want to store only non-null items in a list or set.
When you need to allow some items in a collection to be null.
When you want to avoid crashes caused by null values in collections.
When you want to clearly show if a collection can hold nulls or not.
When working with data that might be missing or optional.