foreach loop
    TheFlyingFiddle via Digitalmars-d-learn 
    digitalmars-d-learn at puremagic.com
       
    Tue Nov  3 16:53:31 PST 2015
    
    
  
On Tuesday, 3 November 2015 at 15:29:31 UTC, Namal wrote:
> well I tried this that way, but my count stays 0, same as if I 
> do it in an int function with a return though I clearly have 
> some false elements in the arr.
You could also use count: 
http://dlang.org/phobos/std_algorithm_searching.html#count
return arr.count!(x => !x);
    
    
More information about the Digitalmars-d-learn
mailing list