Consistent style, use ternary operator and enumerate