What is the difference between _tmain() and main() in C++?

后端 未结 5 1140
悲哀的现实
悲哀的现实 2020-11-22 10:37

If I run my C++ application with the following main() method everything is OK:

int main(int argc, char *argv[]) 
{
   cout << \"There are \" << a         


        
5条回答
  •  隐瞒了意图╮
    2020-11-22 11:02

    the _T convention is used to indicate the program should use the character set defined for the application (Unicode, ASCII, MBCS, etc.). You can surround your strings with _T( ) to have them stored in the correct format.

     cout << _T( "There are " ) << argc << _T( " arguments:" ) << endl;
    

提交回复
热议问题