Question: why iterator is fail fast in java?
Answer: Fail-fast iterators in Java don't play along when the underlying collection gets modified. Collections maintain an internal counter called modCount. Each time an item is added or removed from the Collection, this counter gets incremented.