dimanche 5 mars 2017

What is happening in this if statement? '&' and '<<'

for (int x = 0; x < size; x++) {
    for (int y = 0; y < this.size(); y++){
        if ((x & (1 << y)) > 0)
            ...
        }   
    ...
}

I'm not familiar with a single '&' and the '<<' symbol.

Aucun commentaire:

Enregistrer un commentaire