1: After mingw and GCC compiler are installed, of course mingw is the safest to install and won't be too difficult.
2: Install notepad ++. Needless to say
3: Configure environment variables (Note: it may take effect after restart)
Computer --> properties --> advanced system settings --> environment variable --> Add C: \ mingw \ bin to system: path;
Of course, mingw is installed under drive C and modified according to different paths
4: Open notepad ++, write a C ++ code, and save it.
For example:
# Include <iostream>
Using namespace STD;
Int main (){
Int A, B;
Cout <"input:" <Endl;
While (CIN> A> B ){
Cout <a + B <Endl;
}
Return 0;
}
5: Choose menu bar> RUN> Run. In the pop-up box, enter:
CMD/K g ++-O emerge (name_partcmd.exe "$ (full_current_path)" & pause & Exit
Select the shortcut key and save it as: G ++ compilation. Note that the shortcut key should not be repeated. Click Run in the pop-up box, OK, close notepad, and then open notepad ++;
6: Choose menu bar> RUN> Run. In the pop-up box, enter:
CMD/K "$ (name_part)" & pause & Exit
Similarly, the SAVE name is changed to: G ++ run, and then click Run program to execute