="comment collapse in" id="comment-allSatisfy-c621553c94cc281ceea6176cdad51713"><p>Returns a Boolean value indicating whether every element of a sequence
satisfies a given predicate.</p>
<p>The following code uses this method to test whether all the names in an
array have at least five characters:</p>
<pre><code class="language-swift">let names = [&quot;Sofia&quot;, &quot;Camilla&quot;, &quot;Martina&quot;, &quot;Mateo&quot;, &quot;Nicolás&quot;]
let allHaveAtLeastFive = names.allSatisfy({ $0.count &gt;= 5