mercredi 30 octobre 2019

Convertion from Integer to bool does not work (beginner)

Good evening, I am at the very start of c++ and I can´t understand why

int ival{1};
bool bval{ival};

does not work but

int ival = 1;
bool bval = ival;

works? Thanks for any hints or an answer!

Have a nice evening.

Aucun commentaire:

Enregistrer un commentaire