检索规则说明:AND代表“并且”;OR代表“或者”;NOT代表“不包含”;(注意必须大写,运算符两边需空一格)
检 索 范 例 :范例一: (K=图书馆学 OR K=情报学) AND A=范并思 范例二:J=计算机应用与软件 AND (U=C++ OR U=Basic) NOT M=Visual
作 者:陈亭志[1] 程利民[1] Chen Tingzhi;Cheng Limin(College of Mechanical and Electrical Engineering,Wuhan Polytechnic,Wuhan430074,China)
机构地区:[1]武汉职业技术学院机电工程学院,湖北武汉430074
出 处:《武汉职业技术学院学报》2021年第6期106-112,共7页Journal of Wuhan Polytechnic
基 金:2020年武汉职业技术学院课题“基于输出式学习理论的在线课程有效教学”(项目编号:2020YJ002)。
摘 要:算术表达式的计算是C语言程序设计中经典数学问题,计算机在解决这个问题时,一般是用逆波兰算法,把中缀表达式转化为后缀表达式,然后再使用栈计算实现,这种算法利用递归的思想,并结合栈复杂数据结构才能实现。设计一种算法,通过将运算符进行优先级排序,找到了复杂计算问题的简化模型,只需要应用循环和数组就可以实现复杂算术表达式的计算。The calculation of arithmetic expressions is a classic mathematical problem in C language programming.When a computer solves this problem,it usually uses the inverse Polish algorithm to convert the infix expression into a suffix expression,and then use the stack calculation to implement this algorithm.It can be realized only by using the idea of recursion and combining the complex data structure of the stack.In this paper,an algorithm is designed.By prioritizing operators,a simplified model of complex calculation problems is found.The calculation of complex arithmetic expressions can be realized by using loops and arrays.
分 类 号:TP301.5[自动化与计算机技术—计算机系统结构]
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在链接到云南高校图书馆文献保障联盟下载...
云南高校图书馆联盟文献共享服务平台 版权所有©
您的IP:216.73.216.26