22\5 final. found errors in logic