C++ Specifics
Compiling
g++ a.cpp // compile the cpp file
A .exe
file will be generated in the directory for execution. One needs to compile a c++ file every time before running it! No updates of the code will be reflected otherwise!
Executing
a.exe
in terminal.
Fast I/O
cin.tie(0) -> sync_with_stdio(0);
General Template
#include "bits/stdc++.h"
using namespace std;
int main(){
cin.tie(0) -> sync_with_stdio(0);
// ...
}
Last updated