search
HomeDevelopment ToolsnotepadTeach you how to compile C/C++ using Notepad++

The following tutorial column of notepad will introduce you to the method of compiling C/C with Notepad. I hope it will be helpful to friends in need!

Teach you how to compile C/C++ using Notepad++

##1. Download MinGW and store it in the C drive (You can choose this by yourself).

2. Right-click "Computer" on the desktop - Properties - Advanced System Settings - Environment Variables, find the Path option, double-click to open it, and write ";C:\MinGW\bin" at the end. Pay attention to the semicolon. Separate it from the previous options (this is how it is written in Win7 system). If it is Win10, please see the picture below:


Teach you how to compile C/C++ using Notepad++
Teach you how to compile C/C++ using Notepad++ Then confirm all the way.

3. Open cmd and enter g -v (note that there is a space).

For Win10 users, if these things appear, it means the modification is successful:


Teach you how to compile C/C++ using Notepad++For Win7 users, if these things appear, it means the modification is successful:

4. Open Notepad and press F5 to open the interface as shown:

Teach you how to compile C/C++ using Notepad++

5. Enter

cmd /k chdir /d $(CURRENT_DIRECTORY) & c++ $(NAME_PART).cpp -o $(NAME_PART) &$(NAME_PART).exe

and click Save. Fill in the Name as you like (it is recommended to fill in RunC ), then determine a shortcut key yourself (of course, you can also be unsure, you can find it from "Run" in the menu bar), click OK, and then close the window.

6. Just write a program and press the shortcut key you just set. Will it run?

Teach you how to compile C/C++ using Notepad++

For more notepad related technical articles, please visit

notepad Column!

The above is the detailed content of Teach you how to compile C/C++ using Notepad++. For more information, please follow other related articles on the PHP Chinese website!

Statement
This article is reproduced at:csdn. If there is any infringement, please contact admin@php.cn delete
Installing Notepad  : A Step-by-Step GuideInstalling Notepad : A Step-by-Step GuideApr 25, 2025 am 12:08 AM

Notepad isapowerful,customizabletexteditoridealforcodersandwriters,offeringfeatureslikesyntaxhighlightingandpluginsupport.Toinstall:1)Downloadfromtheofficialwebsite,2)Runtheinstaller,choosingyourlanguageandinstallationoptions,3)Customizepost-install

The Cost of Notepad  : What You Need to KnowThe Cost of Notepad : What You Need to KnowApr 24, 2025 am 12:06 AM

Notepad usage is accompanied by implicit costs of time, learning curve, and productivity losses, but it can be maximized by leveraging plugins, customizing workflows, and combining other tools. Using Notepad may take more time to complete tasks manually, learning its plug-in system and customization functions takes time, and simplicity may lead to productivity loss, but by installing plug-ins such as NppFTP, customizing shortcut keys and interfaces, and combining GitBash and VisualStudioCode, development efficiency can be effectively improved.

Notepad  : Free to Download and Use?Notepad : Free to Download and Use?Apr 23, 2025 am 12:05 AM

Notepad is completely free and open source. 1. It is based on Windows, developed by DonHo, and supports multiple programming languages. 2. Provides syntax highlighting, code folding and other functions, which are lightweight and have low resource consumption. 3. Through macros and plug-ins such as NppExec, tasks can be automated and external commands can be executed. 4. It is recommended to update regularly, explore community resources, and consider other editors according to your needs.

The Notepad   Installation Process: A Detailed ExplanationThe Notepad Installation Process: A Detailed ExplanationApr 22, 2025 am 12:03 AM

Installation steps of Notepad: 1. Visit the official website to download the latest stable version; 2. Run the installation file and click "Next"; 3. Agree to the license agreement; 4. Select the installation path; 5. Select whether to create a desktop shortcut and start menu folder; 6. Complete the installation and start Notepad.

Notepad  : Exploring Pricing and LicensingNotepad : Exploring Pricing and LicensingApr 21, 2025 am 12:12 AM

Notepad is free and open source, and is licensed under the GPLv2. 1. Anyone can use and modify Notepad for free. 2. When used by the enterprise, any modification or extension must be published in GPLv2. 3. The use of commercial products must comply with GPLv2, including public source code.

Notepad  : The Nation Behind the EditorNotepad : The Nation Behind the EditorApr 20, 2025 am 12:08 AM

Notepad originatesfromFrance,createdbyDonHo.1)France'sfocusoneducationandtechnologyfostersinnovation,reflectedinNotepad 'sdesign.2)Theopen-sourceethosalignswithFrenchvaluesofsharingknowledge.3)EfficiencyandperformancearehallmarksofFrenchengineering

Notepad  : Understanding the Financial ModelNotepad : Understanding the Financial ModelApr 19, 2025 am 12:11 AM

Notepad sustainsitselffinanciallythroughdonations,sponsorships,andapluginecosystem.1)Donationsfromusersprovidethemainincome,keepingthetoolfreeandfosteringcommunity.2)Sponsorshipsfromcompaniesofferastableincomewhilemaintainingindependence.3)Apluginec

Accessing Notepad  : Exploring Free OptionsAccessing Notepad : Exploring Free OptionsApr 18, 2025 am 12:07 AM

Free alternatives to Notepad include VisualStudioCode, SublimeText, and Atom. 1. VisualStudioCode supports multiple languages ​​and enhances features through extensions. 2. SublimeText provides an evaluation version, which is fast and has a simple interface. 3.Atom is known for its high customizability and is suitable for personalized needs.

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

ZendStudio 13.5.1 Mac

ZendStudio 13.5.1 Mac

Powerful PHP integrated development environment

MantisBT

MantisBT

Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

Atom editor mac version download

Atom editor mac version download

The most popular open source editor