This file contains hidden or 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 <vector> | |
#include <algorithm> | |
#include <iterator> | |
#include <iostream> | |
#include <sys/time.h> | |
void event(std::vector<char> &v, std::vector<unsigned long long> &sp, std::vector<unsigned long long> &ep) | |
{ | |
char pre_val(0), cur_val(0); | |
unsigned long long pos(0); |
This file contains hidden or 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 <vector> | |
#include <cstdlib> | |
#include <algorithm> | |
#include <iostream> | |
#include <sys/time.h> // for gettimeofday() | |
//#include <cstdint> C++11 Standart only | |
using namespace std; | |
void nozero (std::vector<long long> &v) | |
{ |
This file contains hidden or 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 <vector> | |
#include <cstdlib> | |
#include <algorithm> | |
#include <iostream> | |
#include <sys/time.h> | |
using namespace std; | |
std::pair<int, int> minimax (std::vector<long long> &v) | |
{ |
This file contains hidden or 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 <vector> | |
#include <algorithm> | |
#include <iostream> | |
#include <sys/time.h> | |
#include <cstdlib> | |
using namespace std; | |
int main() | |
{ |
This file contains hidden or 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
- Tune /etc/ssh/sshd_config | |
UseDNS no # Disable DNS lookups | |
GSSAPIAuthentication no # Disable negotation of slow GSSAPI | |
don't forget to restart it, use a script provider to set it , or create it with veewee or snapshot it | |
- Tune Vagrantfile | |
vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"] |