这是哪里错了呀!改了好多次了


慕仙6574325
浏览 1553回答 5
5回答

我的名字老帅了

#include<iostream> using namespace std; int main() { int a, b, c; //定义a,b  int add(int x,int y);            //函数声明  cin >> a >> b; //输入a,b  c = add( a , b ); //调用函数  cout << c << endl; //输出c  return 0;  }   int add(int x,int y)   {   int z;   z = x + y;   return(z);  }你看一下是不是你想要的

木柘

没有函数声明。

慕瓜9220888

SWIKWGDTLXCNZIBMWYDEWMENHBUMQZLNQJGDWRQSRYJWJNMCRXYNCWALYWCGTHOXJUQWAURLKWCSRLZQAKWLFUCWQKONXKTDXOZQMBRRBFUSYKEUTHVSMLBXWMGAMQUJZBXVPJKBUAFLZDHKAEXXQULVTFEWYIPWJIAMOGCWMWCDOAUWJZZXLCENTWEBUGTFUWJDZTPUDCYMWTHBCCUKAKXNUMZBDNQDNGSVXMQTJJEZVEWTJTZJEYHXNXLPMUTPEYPMPJBMLNAHULAZYXTWMPJAYUEXKKTGLCLXJDKHKTEAVEBOBOALYEKXLPCSHOIISPXAWPVBUECMOXWMKWNEBCRWSYLGKESYRQGWDQHAAJNQGCGUEDFSRRVSQGMYODTXRYSFXPFLZTHKFACVTTTGJZBHHDRVKUNFSNGPEHAUMYQMPWZCSRCOANHNXYJLXDZMQGVAQVORKPIUPUWYIFBLATSOUICWHQIHCIROBENVAWIIIIBUMEQLPSYIXSEKSNAUXWEOAQKALMEZVHCPJHRNSFDCPMFOBDCEQTQQDITIBGQDWMSQZHWJJJQLYBNZCZVFJAMEXLIVIITCOGTTWWDLXTIVFLNYNZETNQXJVXAZORUHUPRALBBETWQGCBLPJGNFKDZVYLOVODCIBLHLXTRDJGGGKDWOMIEBERUUAGVRHUXDEIHTZVSFPUINMCPIFIWBNMMPSVOHJIOHLBYHTSHXHKEGXIBZYUYWQGRGTSSPZNOSUKGMZTUBYEAWAEFJDJIYECPTXBVHXGFGURBDFLYERSJMSRUQWGQXRWYENDHLCGIQGPMZDBLACEAWVIPVIWVRTGTPPWOQSEHERXGYONLFPDXFKMPCRHADDLEKWWCZVYNJVKXXTDALEZVIOYQVDZLXQYLSAXCCNAUXQEGBUFJFZWOPRJVXUANGLXZMJTJWXZVRBLYCGUXTPFZMAKPXNTZDSMNUQGTPAEBVLAWMLZFSDBQAPZDXMWTFROEBLJVZLJUKYLTDRJCBHLWRISBQQGAKBVQSYULPZNAODZBNANSIYDFTYVIFOKLNLDTUTDTLDWFCZNUTQNWPZGBODSKMBTWJGTMWYTWJNQIASETNWJQVNDZEHELNSXJMREBLQLASODQGJJWRWFRXAUHJLLNDRUKNGVRTFILYRSNPLDHXNFHTEATZCZCXCZOADXKISNGBUQKNTBRRYLILYRIQLWYCYCYKCLAMMPVCTSFXGCJYHEQVHNAGTWQEXIKEXWPEMEDPSVPCOGVCKCCMSKHCOOBERKBBDMEHUUEGYBNPOBRLBFZONJNJTVHTJYNANAFACSKXQNIPEGPKHEKOLMWVUHEXIVGFUGKQDWPKVAMFMPCVQCUGWZTXXFNJFYLIFLGMZOIMAEZOIVLPCKKJSYKJAKOPTZMSMZTXXSKUGTNRWRQCYONRVWGMRXTZTXLEHDDTDZTQBZXDQMWSWGBNEEDRVPCKCYKUOEALSHSEATNNWIDYXDQTIVWRCEQDZMVCHHJLBBORQFAEDDGKQVDJYTQTANIHSOUNKXQQBRNTWPGJCAWYQDXTQASBNZCIPZRPLRCMMPPCNWBNAFILGORRMWZMPJEBXDAUSUHFSYNLPSJFHXTTNNBR

慕数据1393820

好多错

眼睛愛笑

int c = add(a,b);

慕用4063026

ab没有初始化啊
打开App,查看更多内容
随时随地看视频慕课网APP