jeudi 23 février 2017

How to check how many true and how many false items is in Array (SWIFT3) [duplicate]

This question already has an answer here:

I need some help. I want to check how many booleans (true,false) is in array. How to check this using only if statement.

var voteArray: Bool = [true,false,true,false,true,true,false,false,true]

and then, add [true] to other array, and [false] to other

Aucun commentaire:

Enregistrer un commentaire