提示:文章写完后,目录可以自动生成,如何生成可参考右边的帮助文档
文章目录
前言
提示:这里可以添加本文要记录的大概内容:
例如:随着人工智能的不断发展,机器学习这门技术也越来越重要,很多人都开启了学习机器学习,本文就介绍了机器学习的基础内容。
提示:以下是本篇文章正文内容,下面案例可供参考
一、初始
1.1安装
下载链接:Download Visual Studio Code - Mac, Linux, Windows
下载支持win7的版本,下载链接:Visual Studio Code July 2022
安装弹出下图,点确定
安装中
安装完成
参考:
第二篇:在 VsCode 上编写和调试 C 语言程序_vscode调试c语言-CSDN博客
第三篇,关于路径:浅谈vscode中指代工作区或项目的路径等配置_vscode workspacefolder-CSDN博客
二、新建一个c文件
2.1、安装插件设置成中文
vscode设置中文界面的方法:1、打开vscode,按【ctrl+shift+p】组合键;2、搜索并选择【configure display language】;3、安装中文简体语言,并重启vscode即可
2.2新建c文件
写一个c代码test.c
cpp
#include "stdio.h"
int main()
{
printf("this is a vscode demo!");
int i;
printf("Input a number here:");
scanf("%d", &i);
printf("We got the %d", i);
system("pause");
return 0;
}
根据参考别人的帖子,最后验证下面的几个文件是可行的。
c_cpp_properties.json文件
cpp
{
"configurations": [
{
"name": "windows-gcc-x86",
"includePath": [
"${workspaceFolder}/**"
],
"compilerPath": "D:/APP/codeBlock/MinGW/bin/gcc.exe",
"cStandard": "${default}",
"cppStandard": "${default}",
"intelliSenseMode": "windows-gcc-x86",
"compilerArgs": [
""
]
}
],
"version": 4
}
launch.json文件
cpp
{
"version": "0.2.0",
"configurations": [
{
"name": "C/C++ Runner: Debug Session",
"type": "cppdbg",
"request": "launch",
"args": [],
"stopAtEntry": false,
"externalConsole": true,
"cwd": "d:/AppData/VsCode/testDemo916",
"program": "d:/AppData/VsCode/testDemo916/build/Debug/outDebug",
"MIMode": "gdb",
"miDebuggerPath": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
]
}
]
}
settings.json
cpp
{
"C_Cpp_Runner.cCompilerPath": "gcc",
"C_Cpp_Runner.cppCompilerPath": "g++",
"C_Cpp_Runner.debuggerPath": "gdb",
"C_Cpp_Runner.cStandard": "",
"C_Cpp_Runner.cppStandard": "",
"C_Cpp_Runner.msvcBatchPath": "",
"C_Cpp_Runner.useMsvc": false,
"C_Cpp_Runner.warnings": [
"-Wall",
"-Wextra",
"-Wpedantic",
"-Wshadow",
"-Wformat=2",
"-Wconversion",
"-Wnull-dereference",
"-Wsign-conversion"
],
"C_Cpp_Runner.enableWarnings": true,
"C_Cpp_Runner.warningsAsError": false,
"C_Cpp_Runner.compilerArgs": [],
"C_Cpp_Runner.linkerArgs": [],
"C_Cpp_Runner.includePaths": [],
"C_Cpp_Runner.includeSearch": [
"*",
"**/*"
],
"C_Cpp_Runner.excludeSearch": [
"**/build",
"**/build/**",
"**/.*",
"**/.*/**",
"**/.vscode",
"**/.vscode/**"
],
"C_Cpp_Runner.useAddressSanitizer": false,
"C_Cpp_Runner.showCompilationTime": false,
"C_Cpp_Runner.msvcWarnings": [
"/W4",
"/permissive-",
"/w14242",
"/w14287",
"/w14296",
"/w14311",
"/w14826",
"/w44062",
"/w44242",
"/w14905",
"/w14906",
"/w14263",
"/w44265",
"/w14928"
],
"C_Cpp_Runner.useUndefinedSanitizer": false,
"C_Cpp_Runner.useLeakSanitizer": false,
"C_Cpp_Runner.useLinkTimeOptimization": false,
"C_Cpp_Runner.msvcSecureNoWarnings": false
}
tasks.json
cpp
{
"version": "2.0.0",
"tasks": [
{
"type": "cppbuild",
"label": "C/C++: gcc.exe build active file",
"command": "D:/APP/MinGWposix/mingw64/bin/gcc.exe",
"args": [
"-pthread",
"-fdiagnostics-color=always",
"-g",
"${file}",
"-o",
"${fileDirname}\\${fileBasenameNoExtension}.exe",
""
],
"options": {
"cwd": "D:/APP/MinGWposix/mingw64/bin"
},
"problemMatcher": [
"$gcc"
],
"group": "build",
"detail": "compiler: D:/APP/MinGWposix/mingw64/bin/gcc.exe"
},
{
"type": "cmake",
"label": "CMake: configure",
"command": "configure",
"problemMatcher": [],
"detail": "CMake template configure task",
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
2.3 说明
1、这个工程还安装了Code runner插件,会在右上角三角形图标下拉菜单下增加一个run code选项。
2、按F5的时候会有一个console窗口,输入字符串后会一闪而过,代码中增加system("pause");可以正常显示代码运行结果。
3、执行"运行C/C++文件"后,代码会在终端显示执行结果。
4、执行"调试C/C++文件"后,代码会进行debug。
5、以上四个文件可以重复使用。
该处使用的url网络请求的数据。
总结
提示:这里对文章进行总结:
例如:以上就是今天要讲的内容,本文仅仅简单介绍了pandas的使用,而pandas提供了大量能使d我们快速便捷地处理数据的函数和方法。