Python String Length Function In Cpp