This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <fstream> | |
#include <vector> | |
#include <cassert> | |
#include <limits> | |
#define WIN32_LEAN_AND_MEAN | |
#include <windows.h> | |
namespace std { }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2148 | |
9058 | |
7742 | |
3153 | |
6324 | |
609 | |
7628 | |
5469 | |
7017 | |
504 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <map> | |
#include <cassert> | |
#include <climits> | |
namespace std { }; | |
using namespace std; | |
struct node | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <fstream> | |
#include <vector> | |
#include <time.h> | |
#include <math.h> | |
#include <cassert> | |
namespace std { }; | |
using namespace std; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2148 | |
9058 | |
7742 | |
3153 | |
6324 | |
609 | |
7628 | |
5469 | |
7017 | |
504 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <fstream> | |
#include <vector> | |
#include <map> | |
#include <algorithm> | |
#include <cassert> | |
namespace std { }; | |
using namespace std; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <fstream> | |
#include <vector> | |
#include <cassert> | |
namespace std { }; | |
using namespace std; | |
istream& operator>>(istream& is, vector<vector<size_t> >& graph) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2148 | |
9058 | |
7742 | |
3153 | |
6324 | |
609 | |
7628 | |
5469 | |
7017 | |
504 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifdef _MSC_VER | |
#define _CRT_SECURE_NO_WARNINGS | |
#endif | |
#include <iostream> | |
#include <cstring> | |
#include <cassert> | |
#include <sys/stat.h> | |
#define WIN32_LEAN_AND_MEAN |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def get_factorial_recursively(i): | |
f = 1 | |
if i > 1: | |
f = f * i * get_factorial_recursively(i - 1) | |
return f | |
def get_factorial_iteratively(i): | |
f = 1 | |
for j in range(2, i + 1): | |
f = f * j |
OlderNewer