Header Ads Widget

Ticker

6/recent/ticker-posts

How to reduce the execution time of program in c++.

 We can simply use two sentence in the body of main can reduce the execution time in cpp;

ios_base::sync_with_stdio(false);
    cin.tie(NULL);


When we use this it reduces execution time of the program .

Generally we use this in competitive programming

Example:-

#include <bits/stdc++.h>
using namespace std;

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    return 0;
}



Recommended Post:

Key points:-

Cracking the coding interview:-

 Array and string:-

Tree and graph:-

Hackerearth Problems:-

Hackerrank Problems:-

Data structure:-

 MCQs:-

Post a Comment

0 Comments