0
Can you tell me how to convert int to bool, please
5 ответов
+ 3
E.Q Why you want to convert int to bool because bool contains only 2 value true or false. So when you will convert 0 to bool it will give false other than 0 you will always get true.
Convert.ToBoolean() gives output in bool but you have assigned to int which is wrong.
int nota = Convert.ToBoolean(nota);
should be
bool notaa = Convert.ToBoolean(nota);
+ 2
E.Q Then why you want to convert number in bool?
0
I want to count negative (x <10) and positive (x> 10) values
0
AJ #Infinity Love
Bool does not serve to make counts, besides true and false