用户:
长大,是我们儿时的梦想查看:0 回复:0 评论:0 创建时间:2021-12-25T15:01:13
e,从哪开始?imgsrc="https://static.codemao.cn/emoji/codemao/%E7%BC%96%E7%A8%8B%E7%8C%AB_%E5%86%B7%E6%BC%A0.gif"alt="emotion_编程猫_冷漠" 首先,从定义一个函数开始 函数类型函数名称(参数) { //函数主体; return返回值; } void?它是一种函数定义类型,表示没有任何返回值。 写一个简单的函数 voidhello(){ cout>>"helloword"; } 函数有了,该怎么调用? 就像这样。 函数名称(参数); 标准代码 //我头文件,敲的头疼,不打了 voidhello(){ cout>>"helloword"; } intmain() { hello(); return0; } 我想屏幕前的你应该会了,再见 imgsrc="https://static.codemao.cn/emotion/thunder_monkey/%E5%9B%B4%E8%A7%82.gif"alt="emotion_雷电猴_围观"imgsrc="https://static.codemao.cn/emotion/thunder_monkey/%E9%9B%B7%E7%94%B5%E7%8C%B4z.gif"alt="emotion_雷电猴_嗯嗯"