Skip to content

Instantly share code, notes, and snippets.

/*
Being so lame it's still my bachelor's diploma paper part.
feel free to use.
Anatoly Zinovyev (Ender Eyre) 2016 ._.
∧_∧
( ・ω・。)つ━☆・*。
⊂ ノ ・゜+.
しーJ °。+ *´¨)
.· ´¸.·*´¨) ¸.·*¨)
(¸.·´ (¸.·'* ☆
@EnderEyre
EnderEyre / knapsack.cpp
Created December 24, 2016 00:48
My solution of integer backpack problem with brute-force. Just to gain skills.
#include <iostream>
#include <vector>
using namespace std;
static long long FactNaive(int n)
{
long long r = 1;
for (int i = 2; i <= n; ++i)
r *= i;
#include <string>
#include <iostream>
#include <vector>
#include <unordered_map>
#include <boost/spirit/include/qi.hpp>
#include <boost/spirit/include/phoenix.hpp>
class ADefinition;
using namespace std;
@EnderEyre
EnderEyre / ev
Created June 18, 2014 17:44
kinda evaluator, testing now.
#include <iostream>
#include <stdexcept>
#include <vector>
#include <unordered_map>
using namespace std;
class ADefinition;
typedef unordered_map <string, int> vmap;
typedef unordered_map <string, ADefinition*> FMAP;