Forward slash or backslash when declaring includes on C++ [duplicate] - c++

This question already has answers here:
Is the backslash acceptable in C and C++ #include directives?
(6 answers)
Closed 5 years ago.
I had always used <bits/stdc++> library for my codes, however, I noticed that <bits\stdc++.h> works as well on CodeBlocks 16.01 on GNU GCC compiler, Windows 7/10 environment.
My question is Which of those is right, and if not both, why is one wrong?
I have successfully compiled code with that include in more than one computer.

Which of them is right, if the both are not, why is one of them right and the other one not?
Only the forward slash / is right. Compilers under Windows systems use an extension that can handle both.

Related

How Do You Compile C++ Code Using Vim (Windows)? [duplicate]

This question already has answers here:
How to Compile C++ Code Using Vim on Windows?
(2 answers)
Compiling and Running a C++ Program with Vim [duplicate]
(3 answers)
How do i compile and run a c++ code in vim (windows) [closed]
(3 answers)
How to compile a cpp file directly from vim editor in Windows?
(1 answer)
Closed 11 months ago.
So I've been searching for literally hours but I can't find a good way to compile my C++ codes through GVIM. So I've tried to compile my programs through Window's Command Prompt, but it didn't work out too well because I had to move my files around, which I didn't enjoy at all. I also tried using the :make function in GVIM which for some reason also didn't work. So can someone please just give a detailed instruction on how I can run my C++ codes while using VIM? Thanks!
P.S. There's a YouTuber that I watch and this was what I meant when I was wondering about compiling code: https://www.youtube.com/watch?v=uGrBHohIgQY << Fast Forward to 1:20
Did you make own Makefile? :make will work only when you have created that file.

Which version of c++ does CodeBlocks use? [duplicate]

This question already has answers here:
How can I add C++11 support to Code::Blocks compiler?
(4 answers)
Closed 3 years ago.
Recently I have tried to use some Advance c++ functions in CodeBlocks but all the time it throw errors like " according to c++ 98....... ".
If CodeBlocks uses an old version of c++ can I update it to c++11 or c++14.
I am just a new learner and cordially requesting you to help if you know the answer.
You can set compiler version and language standart in settings.
See this How can I add C++11 support to Code::Blocks compiler?

C++ executable signing in Linux [duplicate]

This question already has answers here:
Signed executables under Linux
(10 answers)
Closed 3 years ago.
I have a set of executable and shared object files in Linux built using GCC. I am looking for a way to digitally sign these. What could be the best way in Linux equivalent to Sign Tool for Windows?
If you create AppImage executables, you can sign them. See https://docs.appimage.org/packaging-guide/optional/signatures.html

mingw 5.2 strange message with std::string [duplicate]

This question already has answers here:
the procedure entry point __gxx_personality_v0 could not be located
(5 answers)
Closed 3 years ago.
a program with std::string anywhere will compile fine, but when run it fails with the message
The procedure entry point
_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev could not be located in the dynamic link library libstdc++-6.dll.
I cannot find more information on it though, how can I remedy this problem?
turns out I had the wrong compiler, I needed 4.8 from the other MinGW

How to use old commands in new compilers? [duplicate]

This question already has answers here:
Conio.h not working in codeblocks (Undefined reference to ..)
(5 answers)
Closed 7 years ago.
I am making a record entry system in C++. In this system, I need to use commands like gotoxy,clrscr,sound,nosound,etc. I work in Code::Blocks IDE and use a GNU GCC compiler. For the gotoxy command, I even downloaded the header file but still it does not work. Can anyone give me the code or the duplicate of these functions.Thanks!
The problem is that <conio.h> does not work on modern compilers . It only works on old IDE's ones like TurboC++ and DevC++ ( They are very old, TurboC++ was used in the 20th century, no one hardly uses it anymore ). So, in short, it won't work unless you get an old compiler ( which is not a good idea ).
<conio.h> is ancient.
<conio.h> was commonly used in Turbo C, to manipulate the console input/output. This was prominent in the old DOS age, where most of the things were command-line.
As for now, <conio.h> is not supported in gcc.