c语言注释的写法

来源:百度知道 编辑:UC知道 时间:2024/05/09 11:11:29
c语言注释的写法 本人不太会写 想要一些建议
格式我会 只是不知道怎样写好 清晰美观又简洁

一楼的已经写出了正确的写法
不过在使用C语言的注释时一定要注意不要嵌套使用

/*
注释内容
*/

/*
* an example of comment
*/

#include <iostream>

using namespace std;

int main()
{
......// an example of comment
......

// an expmple of comment
......
......

return 0;
}

就是写一下你的这句话的 意思 循环的目的 函数的功能 什么的
/* 。。。 */里面写注释
// 后面写注释的(VC++)