Simplify ternary expression thing