fixed pythons evaluation of conditions... still working on c++