当前位置: 首页 > news >正文

贸易型企业网站建设网站开发后台指什么

贸易型企业网站建设,网站开发后台指什么,vps wordpress cpu占用过高,一二三四视频社区C程序设计语言 #xff08;第二版#xff09; 练习 4-8 练习 4-8 假定最多只压回一个字符。请相应地修改getch与ungetch这两个函数。 注意#xff1a;代码在win32控制台运行#xff0c;在不同的IDE环境下#xff0c;有部分可能需要变更。 IDE工具#xff1a;Visual St…C程序设计语言 第二版 练习 4-8 练习 4-8 假定最多只压回一个字符。请相应地修改getch与ungetch这两个函数。 注意代码在win32控制台运行在不同的IDE环境下有部分可能需要变更。 IDE工具Visual Studio 2010 代码块 #include stdio.h #include stdlib.h #include ctype.h #include math.h #include string.h#define MAXOP 100 #define NUMBER 0 #define MAXVAL 100 #define BUFSIZE 100 #define VAR 1int sp 0; double val[MAXVAL];//char buf[BUFSIZE]; int bufp 0; char buf 0;double variable[26];void push(double f){if(sp MAXVAL){val[sp] f;}else{printf(Error! Stack Full, cant push %g\n, f);} }double pop(void){if(sp 0){return val[--sp];}else{printf(Error! Stack Empty!\n);return 0.0;} }void printTop(void){if(sp 0){printf(Top: %g\n, val[sp-1]);}else{printf(Error! Stack Empty!\n);} }void topCopy(void){if(sp 0 || sp MAXVAL){val[sp] val[sp-1];}else if(sp 0){printf(Error! Stack Empty!\n);}else{printf(Error! Stack Full!\n);} }void swapTop(void){double temp;if(sp 2){temp val[sp-1];val[sp-1] val[sp-2];val[sp-2] temp;}else{printf(Cant Swap Top Number!\n);} }void emptyStack(void){for(int i sp - 1; i 0; i--){val[i] 0;}sp 0; }int getch(void){int c;c (buf ! 0) ? buf : getchar();buf 0;return c; }void ungetch(int c){if(buf ! 0){printf(Ungetch! Too many characters!\n);}else{buf c;} }void ungets(char s[]){int len strlen(s);for(int i 0; i len; i){ungetch(s[i]);} }int getop(char s[]){int i, c;while((s[0] c getch()) || c \t);s[1] \0;if(c s){int next1 getch();int next2 getch();if(next1 i next2 n){return c;}}if(c e){int next1 getch();int next2 getch();if(next1 x next2 p){return c;}}if(c p){int next1 getch();int next2 getch();if(next1 o next2 w){return c;}}if(c a c z){int next getch();if(next ){ungetch(next);return VAR;}}if(c -){int next getch();if(!isdigit(next) next ! .){ungetch(next);return c;}s[1] c next;i 1;}else{i 0;if(!isdigit(c) c ! .){return c;}}if(isdigit(c)){while(isdigit(s[i] c getch()));}if(c .){while(isdigit(s[i] c getch()));}s[i] \0;if(c ! EOF){ungetch(c);}return NUMBER; }int main(){int type;double op2;char s[MAXOP];while((type getop(s)) ! EOF){switch(type){case NUMBER:push(atof(s));break;case :push(pop() pop());break;case *:push(pop() * pop());break;case -:op2 pop();push(pop() - op2);break;case /:op2 pop();if(op2 ! 0.0){push(pop() / op2);}else{printf(Error! Zero Divisor!\n);}break;case %:op2 pop();push((int)pop() % (int)op2);break;case s:op2 pop();push(sin(op2));break;case e:op2 pop();push(exp(op2));break;case p:op2 pop();push(pow(pop(), op2));break;case VAR:variable[s[0] - a] pop();push(variable[s[0] - a]);printf(%c %lf\n, s[0], variable[s[0] - a]);break;case \n:printf(\t%.8g\n, pop());break;default:printf(Error! Unknown Command %s\n, s);break;}}system(pause);return 0; }
http://www.zqtcl.cn/news/366645/

相关文章:

  • 营销型网站怎么收费邓州企业网站
  • 北京建设官方网站邢台网站维护
  • 新余网站制作网站开发工资咋样
  • 襄阳网站建设外包自己做一个网站
  • 网站域名的后缀wordpress文章归类
  • 查询企业信息的官方网站大连建设网站公司
  • 网站建设 全包专业建设规划方案模板
  • 做网站好还是做微信小程序好浙江建设工程造价信息网站
  • 网站开发怎么报价推广普通话手抄报模板可打印
  • 好的平面网站模板企业网站建设浩森宇特
  • 做网站通过什么赚钱吗公司建设网站的费用
  • 如何做建筑一体化的网站视频网站开发应用到哪些技术
  • 巴中微信网站建设竞价托管一般多少钱
  • 彩票网站开发 违法股票网站排名哪个好
  • 宝格丽网站建设哈尔滨网站建设王道下拉強
  • 烟台网站建设的公司世界500强企业排名2021
  • 网络营销做得比较成功的案例吴中seo网站优化软件
  • 怎么设立网站美区下载的app怎么更新
  • 建立网站ppt做酒店网站所用到的算法
  • 上海网站建设的价格低太仓做网站的公司
  • 怎样登录建设互联网站怎么做中英文网站
  • 云网站7china中小企业网站建设好么
  • 美丽南方官网网站建设国际新闻最新消息今天摘抄
  • 牛商网营销型网站多少钱江门营销型网站建设多少钱
  • 小榄公司网站建设网站交互做的比较好的
  • 深圳定制网站建设怎么改版网站
  • 免费学软件的自学网站江阴建设局网站
  • 网站做多久苍南县网站集约化建设
  • 深圳电子烟网站建设罗湖建设公司网站建设
  • 酒店 深圳 网站建设新项目首码对接平台