广告广告
  加入我的最爱 设为首页 风格修改
首页 首尾
 手机版   订阅   地图  繁体 
您是第 1981 个阅读者
 
发表文章 发表投票 回覆文章
  可列印版   加为IE收藏   收藏主题   上一主题 | 下一主题   
ice27315
数位造型
个人文章 个人相簿 个人日记 个人地图
路人甲
级别: 路人甲 该用户目前不上站
推文 x0 鲜花 x0
分享: 转寄此文章 Facebook Plurk Twitter 复制连结到剪贴簿 转换为繁体 转换为简体 载入图片
推文 x0
[C/C++][求助] 作业程式错误
Write a C program that uses array method to implement stack operations.

请问是哪边错?




#include <stdio.h>
#include<stdlib.h>

struct abc
{
int i;
int j;
int l;
int control;
int array;
};

int main (void)
{
struct abc ok;

while((ok.control=getchar())!=EOF)
{
for(ok.i=0;ok.i<15;ok.i++)
{ printf(" please select a operation\n-----------------------------\n <1> push value into stack\n <2> pop value out of stack\n <3> print stack\n <-1> terminate\n-----------------------------\n>");
scanf("%d",&ok.control);

switch(ok.c ..

访客只能看到部份内容,免费 加入会员 或由脸书 Google 可以看到全部内容




献花 x0 回到顶端 [楼 主] From:台湾中华电信 | Posted:2010-04-06 00:42 |

首页  发表文章 发表投票 回覆文章
Powered by PHPWind v1.3.6
Copyright © 2003-04 PHPWind
Processed in 0.013768 second(s),query:15 Gzip disabled
本站由 瀛睿律师事务所 担任常年法律顾问 | 免责声明 | 本网站已依台湾网站内容分级规定处理 | 连络我们 | 访客留言