New blog domain: kula.blog

It's still work in progress but new posts will be published on  https://kula.blog/ Thanks to 11ty base blog RSS is working from the start so it should be easy to add to your reader if you still use any :) If now then I hope you can sign up to the newsletter where I'll be publishing new posts and interesting articles to it from time to time. Please use  kula.blog  from now on.

Boolean in loop

Reading about Lookups I found new(for me) and awesome way to manage boolean value  used for controlling loops:



        boolean valid = false;
        while(!valid){
            id = this.getId();
            valid = true;
            for(IdValidator validator : rstl.allInstances()){
                valid = valid && validator.validate(id);
            }
        }
  
Using && really make me thinking why I didn't figure it out yet!

Comments

Popular posts from this blog

How to simulate slow connection (developer proxy in Node.js)

Safari Mobile CSS VW and VH units bug.