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 <iostream> | |
| #include <memory> | |
| using namespace std; | |
| template<class T> struct Node | |
| { | |
| unique_ptr<Node<T>> nextNode; | |
| T value; | |
| }; |
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 <xmmintrin.h> | |
| #include <iostream> | |
| #include <iomanip> | |
| #include <random> | |
| #include <vector> | |
| #include <sstream> | |
| #include <chrono> | |
| using namespace std; | |
| union alignas(16) Float16 |
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 <iostream> | |
| #include <random> | |
| #include <sstream> | |
| using namespace std; | |
| void RollDice(mt19937_64& mt, int n) | |
| { | |
| uniform_int_distribution<int> distribution(1, 30); | |
| int matchCount = 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
| /// Switch statements will use a structure closer to that of if-statements: | |
| /// they are one line unless you use braces. | |
| /// No more break statements. The _default_ behavior is breaking out of a block. | |
| /// Fallthrough is achieved through either comma-separates lists or 'jump' keyword. | |
| switch (value) | |
| { | |
| // One line style. | |
| case (7) DoSomething(); |
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
| ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDjNzMK5n0vL9gHiqrN0UzTRjCoOx7Ir2axp65QkXmdLpbkKvFhSm21OmI967wkXf6MZkth8gZoufnTY31dIAhccihmf3NMnlVY9pIRx4+i+7juaZIRqlnKDUoWr0uyoLAKhtqRwjkVMvkuThvlkc+zQRd7S8OHyP0kwG3yPonwsPvPrXhSf1Eo1fAsNfLZWOHgm9QEXS3Ms+RPVIAa1M+S8FODXlEG9d9SfR0bEK81LB49i6bOs8zgCt1M5P7rmt2WBtVRbOvubjr25JUb9A5rdRn+b3kBlSgQpAzzUlbdzACdsN7V5K5u8AFeq+T/7zr3jKqUNeJ5iBJyHpV+jaHb kellyb@kellyb-xubuntu |
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 <libpq-fe.h> | |
| #include <iostream> | |
| using namespace std; | |
| int main(int argc, char** argv) | |
| { | |
| PGconn* connection = PQconnectdb( | |
| "host=localhost port=5432 dbname=swccg user=postgres"); | |
| if (PQstatus(connection) == CONNECTION_OK) |
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
| The greatest scientists of all time were invited to a conference ... | |
| * Newton said he'd drop in. | |
| * Descartes said he'd think about it. | |
| * Ohm resisted the idea. | |
| * Boyle said he was under too much pressure. | |
| * Darwin said he'd wait to see what evolved. | |
| * Pierre and Marie Curie radiated enthusiasm. | |
| * Volta was electrified at the prospect | |
| * Pavlov positively drooled at the thought. |
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
| void stackDump() | |
| { | |
| const unsigned char* n; | |
| n = (const unsigned char*)&n; | |
| cout << "fail function: " << (void*)fail << endl; | |
| for (int i = 0; i < 64; ++i) | |
| { | |
| cout << '[' << i << "] " << (void*)n << " --"; |
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 "sqlite3.h" | |
| #include <iostream> | |
| #include <fstream> | |
| #include <unordered_map> | |
| #include <string> | |
| #include <cstring> | |
| using namespace std; | |
| const char OneHalf[] = { (char)0xc2, (char)0xbd, 0x00 }; | |
| const char OneQuarter[] = { (char)0xc2, (char)0xbc, 0x00 }; |
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 <iostream> | |
| using namespace std; | |
| struct Word | |
| { | |
| int n; | |
| const char* text; | |
| }; | |
| int main(int argc, char** argv) |