simplified precedenceClimb
replaced precedence map with switch case function
resolved merge conflict