Skip to content

Instantly share code, notes, and snippets.

@zych1751
zych1751 / 4097.cpp
Created October 8, 2017 08:42
acmicpc.net/4097 : Top-down
#include<bits/stdc++.h>
using namespace std;
int cache[250000];
int arr[250000];
int f(int idx)
{
if(idx == 0) return arr[0];
@zych1751
zych1751 / 4097.cpp
Last active October 8, 2017 08:33
acmicpc.net/4097 : bottom-up
#include<bits/stdc++.h>
using namespace std;
int cache[250000];
int arr[250000];
int main()
{
while(1)