Man sentenced to over four years in federal prison for robbing banks in NH, MA