当前位置:网站首页>VS2019初步使用
VS2019初步使用
2022-07-06 09:25:00 【编程小鱼六六六】
前言
前段时间把电脑重置了下,导致很多软件都被删除了,所以重新安装了,顺便把一些“陈年落后”的软件更新到了最新版。新版的软件和之前相比的确区别很大,更人性化了、功能也增加了不少,体会最深的就是Adobe Photoshop 2020 对新手太友好了,强烈推荐各位用来学习PS。
说回VS,全名是Visual Studio,是Microsoft旗下的一款IDE,被称为“宇宙第一IDE”,基本上流行的编程语言都可以在上面写,十分的“全”,但这些并不被大多数使用者所“倾爱”,“全”意味着“大”也意味着不特长,比如虽然VS支持python,但一般不会用它来写,因为有很好的工具如PyCharm等,Java也一样。
我们一般用VS写C、C++、C#等。其它的不说,本文主要介绍安装VS2019、如何在VS2019中写第一个C语言程序以及安装的一些其它问题。如果你还在用VC++ 6.0 写C语言,赶快给我“干掉”,计算机二级都不用了,你还在用。
- 安装VS2019
- 写第一个C语言程序
- 其它注意事项
安装VS2019
直接到官网下载安装程序,然后安装即行。下载社区版即可,因为它是免费的(只需要注册一个微软帐号),而且对我们一般人来说就足够了。
特别注意 :一定要更改安装路径,因为VS2019会占据大量空间,5,6个G吧。 在选择工作负载的时候选择“使用C++的桌面开发”(配置C语言环境需要,当然你可以根据需要自行选择),建议你把“Visual Studio 扩展开发”也选上,然后安装即可。


最重要的一点就是:一定要联网。 需要一段时间,可以喝杯咖啡。
写第一个C语言程序
安装好了,就是使用的问题了。面对这样一个“庞然大物”,对于新手而言,的确不太友好,想写段简单的C语言还得再走一段路。 step1 :打开VS2019,选择创建新项目。

step2:选择空项目,然后下一步。

step3:更改名称,选择位置,然后创建。

step4:右击方案资源管理器中的源文件,添加,选择新建项。

step5:选择C++文件,更改名称为.c文件(.c为C语言程序,.cpp为C++程序),然后添加。

step6:输入如下代码:
#include <stdio.h>
int main()
{
printf("Hello World !");
return 0;
}
step7:Ctrl+F5,输出如下:

其它注意事项
最后写些在编程过程中的注意事项。 第一个就是字体,建议使用一款容易区分0O1i的字体,推荐Consolas。更改菜单在工具,选项,字体和颜色,然后把文本编辑器、输出窗口,命令窗口的字体都更改。


第二个是VS的项目文件是以.sln为后缀的文件,双击即可打开之前关闭的VS,一定要注意是不是打开以.c为后缀的文件。

第三如果想去除鼠标右击菜单”在Visual Studio中打开 “。

新建个文本文档,输入一下内容:
Windows Registry Editor Version 5.00 [-HKEY_CLASSES_ROOT\Directory\Background\shell\AnyCode] [-HKEY_CLASSES_ROOT\Directory\shell\AnyCode]
保存文档,并将其扩展名重命名为:xxx.reg,,然后双击确定即可。
Visual Studio 2019 中最引人瞩目的就是Visual Studio Live Share,实时协作开发,太强大了。
C/C++入门视频,提供给零基础的小伙伴进行C语言入门学习,学习C/C++编程知识,欢迎关注UP,也可以进入UP的企鹅学习群:828339809 一起进步,更多优质的学习教程持续更新~
边栏推荐
- Mysql database (V) views, stored procedures and triggers
- Preface to the foundations of Hilbert geometry
- Crawler series (9): item+pipeline data storage
- Leetcode notes - dynamic planning -day7
- Research Report of pharmaceutical solvent industry - market status analysis and development prospect prediction
- Cost accounting [16]
- Research Report on medical anesthesia machine industry - market status analysis and development prospect prediction
- Lab 8 file system
- C语言是低级和高级的分水岭
- Mysql database (III) advanced data query statement
猜你喜欢

C4D quick start tutorial - creating models

ucorelab3

Scoring system based on 485 bus

csapp shell lab

Matlab example: two expressions of step function

Es6---es6 content details
Automated testing problems you must understand, boutique summary

学习记录:串口通信和遇到的错误解决方法

ucore lab 6
Future trend and planning of software testing industry
随机推荐
Leetcode notes - dynamic planning -day7
Introduction to safety testing
动态规划前路径问题优化方式
Mysql database (IV) transactions and functions
Research Report on pharmaceutical R & D outsourcing service industry - market status analysis and development prospect forecast
The wechat red envelope cover designed by the object is free! 16888
Stm32 dossiers d'apprentissage: saisie des applications
MySQL transactions
CSAPP shell lab experiment report
FSM和i2c实验报告
Cost accounting [24]
Market trend report, technological innovation and market forecast of pneumonia drugs obtained by Chinese hospitals
ArrayList set
What are the software testing methods? Show you something different
C4D quick start tutorial - Introduction to software interface
Automated testing problems you must understand, boutique summary
Cost accounting [20]
Do you know the advantages and disadvantages of several open source automated testing frameworks?
C语言学习笔记
Cost accounting [14]