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
select | |
i | |
, c | |
, g | |
, gi | |
, sum(1) over (partition by g) gn | |
from ( | |
select | |
i | |
, c |
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
source "https://rubygems.org" | |
gem "csp-solver" | |
gem "terminal-table" |
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
program SQLWorkbenchExplain; | |
{$APPTYPE CONSOLE} | |
uses | |
SysUtils, Classes, JclSysUtils, IniFiles; | |
type | |
TConfig = record | |
LogFile: string; |
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
### Keybase proof | |
I hereby claim: | |
* I am nurettin on github. | |
* I am nurettin (https://keybase.io/nurettin) on keybase. | |
* I have a public key whose fingerprint is 7687 787E A662 029F 2DD6 94CF 9B86 DFB2 25ED E4CB | |
To claim this, I am signing this object: |
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
buildscript { | |
... | |
} | |
... | |
android { | |
... | |
} | |
dependencies { |
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 <fann.h> | |
#include <fann_cpp.h> | |
void prepare_data(std::string const &name){ | |
std::ofstream file(name+ ".data", std::ios::trunc); | |
file<< "4 2 1\n" | |
<< "0 0\n0\n" | |
<< "0 1\n1\n" | |
<< "1 0\n1\n" | |
<< "1 1\n0\n"; |
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 <string> | |
#include <boost/variant.hpp> | |
typedef boost::variant<std::string, double, int> Data; | |
struct Graph: std::map<Data, Graph> | |
{ | |
Data data; |
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
/* | |
The Pwned Combinator is a patten which gives you the ability to store a common base for templated classes in a container | |
while not losing the ability to access the member variables and functions of the derived instance. | |
In this pattern, the base class uses polymorphism to signal usage which then triggers the callable. | |
*/ | |
struct Base | |
{ | |
virtual void use()= 0; |
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 <functional> | |
#include <vector> | |
#include <boost/optional.hpp> | |
struct LazyBase | |
{ | |
std::vector<std::reference_wrapper<LazyBase>> dependents; | |
virtual void nullify()= 0; | |
virtual ~LazyBase(){} | |
}; |
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
// the idea is to benchmark and output pretty results | |
#include <iostream> | |
#include <functional> | |
#include <chrono> | |
#include <vector> | |
struct Fun | |
{ | |
std::string name; |