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 <iterator> | |
| #include <vector> | |
| #include <array> | |
| #include <algorithm> | |
| using namespace std; | |
| typedef unsigned long long CaseType; | |
| template<typename T> | |
| const vector<T> read_test_cases(istream& is) { |
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
| use std::collections::HashMap; | |
| macro_rules! map { | |
| ([$($contents:tt)*] $($parameters:tt)*) => {{ | |
| let mut container = HashMap::new(); | |
| map!(@parameters container, $($parameters)*); | |
| map!(@contents container, $($contents)*); | |
| container | |
| }}; | |
| (@contents $container:expr, $($key:expr => $value:expr),*) => {{ |
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
| #define __USE_MINGW_ANSI_STDIO 1 | |
| #include <stdio.h> | |
| #include <iostream> | |
| #include <fstream> | |
| #include <string> | |
| #include <vector> | |
| #include <chrono> | |
| #include <iterator> | |
| #include <functional> | |
| #include <tuple> |
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 <stdio.h> | |
| #include <fcntl.h> | |
| #include <unistd.h> | |
| #include <string.h> | |
| #include <stdlib.h> | |
| #include <time.h> | |
| #include <sys/types.h> | |
| #include <sys/ioctl.h> | |
| #include <sys/select.h> |
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<netinet/in.h> | |
| #include<errno.h> | |
| #include<netdb.h> | |
| #include<stdio.h> //For standard things | |
| #include<stdlib.h> //malloc | |
| #include<string.h> //strlen | |
| #include<netinet/ip_icmp.h> //Provides declarations for icmp header | |
| #include<netinet/udp.h> //Provides declarations for udp header | |
| #include<netinet/tcp.h> //Provides declarations for tcp header |
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 <stdio.h> | |
| #include <fcntl.h> | |
| #include <unistd.h> | |
| #include <string.h> | |
| #include <sys/types.h> | |
| #include <sys/ioctl.h> | |
| #include <sys/select.h> | |
| #include <net/if.h> | |
| #include <linux/if_tun.h> |
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 <stdio.h> | |
| #include <fcntl.h> | |
| #include <unistd.h> | |
| #include <string.h> | |
| #include <time.h> | |
| #include <sys/types.h> | |
| #include <sys/ioctl.h> | |
| #include <sys/select.h> | |
| #include <net/if.h> |
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 <stdio.h> | |
| #include <fcntl.h> | |
| #include <unistd.h> | |
| #include <string.h> | |
| #include <sys/types.h> | |
| #include <sys/ioctl.h> | |
| #include <sys/select.h> | |
| #include <net/if.h> | |
| #include <linux/if_tun.h> |
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
| template<class Iterator> | |
| struct indirect_iterator { | |
| using iterator_category = typename Iterator::iterator_category; | |
| using value_type = typename Iterator::value_type::value_type; | |
| using difference_type = typename Iterator::difference_type; | |
| using pointer = typename Iterator::value_type::pointer; | |
| using reference = typename Iterator::value_type::reference; | |
| Iterator i; | |
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
| #!/usr/bin/python | |
| import itertools | |
| DEBUG=False | |
| tokens = ('NODE','NUMBER') | |
| literals = ('|','{','}','[',']','$','=',';','~','.','+') | |
| states = ( | |
| ('comment','exclusive'), |
NewerOlder