COSC 3410 Assignment #4 Due: Friday, Oct 15 -ROUGH DRAFT- You can work in teams of two or by yourself. Extend the expanded (*,/) WAE language to include a conditional expression: (if< expr1 expr2 val1 val2) which has the value val1 if (expr1 < expr2) and val2 otherwise. So, {with {a 5} {if< a 10 77 99}} would have the value 77. Add a unary minus [ new tree (minus (operand number?)) ] {with {x -12} {- x}} has value 12 So, new grammar is: ::= | | {+ } | {- } | {* } | {/ } | {- } | {with { } } | {if< } Write an interpreter for this language. Implement error checking for these new expressions (and with). A sample program: {with {x 9} ; you can change these vals, but the larger one should {with {y 3} ; always wind up at the left of the final number ; and the smaller one at the right {with {min {if< x y x y}} {with {max {if< x y y x}} {+ {* max 1000} min} ; output will be best if smaller is }}}} ; no more than two digits