While top of ' ops ' has same or greater precedence to current token , which is an operator . Apply operator on top of ' ops ' to top two elements in values stack
while ( ! ops . empty ( ) && hasPrecedence ( tokens [ i ] , ops . peek ( ) ) ) values . push ( applyOp ( ops . pop ( ) , values . pop ( ) , values . pop ( ) ) ) ;