久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

C/C++ 中 void main 和 int main 的區(qū)別?

Difference between void main and int main in C/C++?(C/C++ 中 void main 和 int main 的區(qū)別?)
本文介紹了C/C++ 中 void main 和 int main 的區(qū)別?的處理方法,對(duì)大家解決問題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)吧!

問題描述

在 C++(或 C)程序中聲明 main 函數(shù)的方式有關(guān)系嗎?

Does it matter which way I declare the main function in a C++ (or C) program?

推薦答案

區(qū)別在于一個(gè)是正確定義main的方式,另一個(gè)不是.

The difference is one is the correct way to define main, and the other is not.

是的,這很重要.要么

int main(int argc, char** argv)

int main()

是根據(jù) C++ 規(guī)范對(duì) main 的正確定義.

are the proper definition of your main per the C++ spec.

void main(int argc, char** argv)

現(xiàn)在不是,也曾經(jīng)是 IIRC,它是舊版 Microsoft 的 C++ 編譯器帶來的反?,F(xiàn)象.

is not and was, IIRC, a perversity that came with older Microsoft's C++ compilers.

https://isocpp.org/wiki/faq/newbie#main-返回-int

這篇關(guān)于C/C++ 中 void main 和 int main 的區(qū)別?的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請(qǐng)聯(lián)系我們刪除處理,感謝您的支持!

相關(guān)文檔推薦

How can I read and manipulate CSV file data in C++?(如何在 C++ 中讀取和操作 CSV 文件數(shù)據(jù)?)
In C++ why can#39;t I write a for() loop like this: for( int i = 1, double i2 = 0; (在 C++ 中,為什么我不能像這樣編寫 for() 循環(huán): for( int i = 1, double i2 = 0;)
How does OpenMP handle nested loops?(OpenMP 如何處理嵌套循環(huán)?)
Reusing thread in loop c++(在循環(huán) C++ 中重用線程)
Precise thread sleep needed. Max 1ms error(需要精確的線程睡眠.最大 1ms 誤差)
Is there ever a need for a quot;do {...} while ( )quot; loop?(是否需要“do {...} while ()?環(huán)形?)
主站蜘蛛池模板: 精品91久久 | 欧美久久一区二区 | 精品久久久久一区二区国产 | 成人av电影免费在线观看 | 国产一区二区在线免费观看 | 精品国模一区二区三区欧美 | 欧美一级欧美一级在线播放 | 色综合久久天天综合网 | 欧美成人一级 | 精品国产乱码久久久久久闺蜜 | 免费国产黄 | 欧美看片| 在线观看午夜视频 | 久久久99精品免费观看 | 最近中文字幕在线视频1 | 自拍偷拍亚洲视频 | 亚洲中午字幕 | 一区二区三区精品视频 | 男女羞羞视频大全 | 亚洲视频在线播放 | 国产午夜精品一区二区三区 | 国产一区二区三区四区在线观看 | av片在线播放 | 久久九九色 | 日韩成人一区 | 久久久精彩视频 | www.狠狠干 | 亚洲久久一区 | 国产精品99免费视频 | 综合色在线 | 国产免费一区二区三区最新6 | 青青激情网 | 日韩影音 | 久久久久久久久久毛片 | 成人免费在线 | 综合国产| 岛国毛片在线观看 | 欧美日韩一区二区三区在线观看 | 亚洲国产精品99久久久久久久久 | 91国内精品久久 | a在线视频|