bool value can be added algorithmly in C