reformated
bool function now complies
num function updated