return the result (was not needed in cmdline version)