mercredi 31 janvier 2018

C++ which if/else is faster

I have seen two types of if/else, which one is faster?

if(a==b) cout<<"a";
else cout<<"b";

OR

a==b ? cout<<"a" : cout<<"b";

Aucun commentaire:

Enregistrer un commentaire