Tools, FAQ, Tutorials:
"Hello.c" - Compile and Run C Program
How to use Visual Studio command tools to compile and run a C program?
✍: FYIcenter.com
If you want to compile and run a standard C program with Visual Studio command tools,
you can follow this tutorial:
1. Create a simple C program, Hello.c, with a text editor:
#include <stdio.h>
void main() {
printf("Hello world!");
}
2. Run "All Programs > Visual Studio 2017 > Visual Studio Tools > Developer Command Prompt for VS 2017". You see the Visual Studio Command Prompt window.
3. Compile and link the C program:
C:\fyicenter>cl Hello.c Microsoft (R) C/C++ Optimizing Compiler Version 19.10.25019 for x86 Copyright (C) Microsoft Corporation. All rights reserved. Hello.c Microsoft (R) Incremental Linker Version 14.10.25019.0 Copyright (C) Microsoft Corporation. All rights reserved. /out:Hello.exe Hello.obj
4. Run the C program:
C:\fyicenter>Hello.exe Hello world!
⇒ "cl" - Compile and Link C++ Program
⇐ Start Visual Studio Command Prompt
2017-08-21, ∼3116🔥, 0💬
Popular Posts:
How to Instantiate Chaincode on BYFN Channel? You can follow this tutorial to Instantiate Chaincode ...
What is EPUB 2.0 Metadata "dc:publisher" and "dc:rights" elements? EPUB 2.0 Metadata "dc:publisher" ...
How to use the XML to JSON Conversion Tool at freeformatter.com? If you want to try the XML to JSON ...
Tools, FAQ, Tutorials: JSON Validator JSON-XML Converter XML-JSON Converter JSON FAQ/Tutorials Pytho...
How To Protect Special Characters in Query String in PHP? If you want to include special characters ...