How to find the value of arithmetic expression by operator priority method in data structure textbook?

CSDN Q & A 2022-02-13 06:10:09 阅读数:595

value arithmetic expression operator priority

Design a small relational arithmetic unit , It can realize simple relational operation , Operators include >、<、==、>=、<=、!=, The operands involved in the operation are symbolic variables a、b.
(1) Input requirements : Multiple sets of test data can be entered , Each set of data corresponds to an expression , When the input ‘#’ End of input .
(2) Output requirements : Output to each group of data 2 That's ok , The first 1 Behavior expression , The first 2 Result of behavior evaluation .

copyright:author[CSDN Q & A],Please bring the original link to reprint, thank you. https://en.javamana.com/2022/02/202202130610078124.html