Skip to content

Instantly share code, notes, and snippets.

@Yangff
Yangff / 2105.cpp
Created December 17, 2013 07:51
BZOJ2105(TLE)
#include <cstdio>
#include <cstdlib>
#include <algorithm>
#include <ext/rope>
#include <cstring>
using namespace std;
using namespace __gnu_cxx;
char buff0[111111],buff1[111111];
bool check(rope<char> &str, int x,int y, int i){
@Yangff
Yangff / Set.coffee
Last active December 24, 2015 23:39
A javascript multiset with O(logN) insert , delete and Query.
class Set
constructor :(array=[])->
@ary = array
@pos = {}
for value,key in @ary
if @pos.hasOwnProperty value
@pos[value].push key
else
@pos[value] = [key]
@Yangff
Yangff / trainJIT.cpp
Last active December 20, 2015 00:19
NOI2013 Day1 T3 JIT
#include <cstring>
#include <cstdio>
#include <cstdlib>
#include <cassert>
#include <map>
#include <cctype>
#ifdef _WIN32
#include <Windows.h>
#endif
using namespace std;