simplify main