add assignment works, so all paths works now, refactor code next