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
//http://coj.uci.cu/24h/problem.xhtml?abb=1005 | |
#include <cstdio> | |
#include <cstdlib> | |
#include <algorithm> | |
#include <cstring> | |
using namespace std; | |
struct plane { | |
int st, end, prize; |
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
//http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=24&page=show_problem&problem=565 | |
#include <iostream> | |
#include <cstdio> | |
#include <cstring> | |
#include <cstdlib> | |
#include <cctype> | |
#include <algorithm> | |
#include <map> | |
#include <vector> | |
#include <list> |
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
//http://coj.uci.cu/24h/problem.xhtml?abb=1962 | |
#include <cstdio> | |
#include <cstdlib> | |
#include <algorithm> | |
using namespace std; | |
int memo[50005]; | |
int cache[50005]; | |
int cows[50005]; |
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
//https://code.google.com/codejam/contest/433101/dashboard#s=p0 | |
#include <cstdio> | |
using namespace std; | |
int main() { | |
int t, n, k; | |
scanf("%d", &t); |
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
//http://www.spoj.com/problems/GNY07H/ | |
#include <cstdio> | |
#include <cstdlib> | |
#include <cstring> | |
#include <vector> | |
#define MAXN 100000 | |
using namespace std; |
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
//http://www.spoj.com/problems/ASSIGN/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#define MAXN (1 << 22) | |
int n; | |
int asuka[22]; | |
long long int memo[MAXN]; |
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
//http://lightoj.com/volume_showproblem.php?problem=1057 | |
#include <cstdio> | |
#include <cstring> | |
#include <algorithm> | |
#include <map> | |
using namespace std; | |
int n, m; | |
int gold; |
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
//http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=24&page=show_problem&problem=1406 | |
#include <cstdio> | |
#include <algorithm> | |
using namespace std; | |
int main() { | |
int n, m, t; | |
while(scanf("%d %d %d", &m, &n, &t) != EOF) { | |
int dp[10005]; |
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
//http://www.spoj.com/problems/AGGRCOW/ | |
#include <cstdio> | |
#include <algorithm> | |
using namespace std; | |
bool feasible(int *a, int n, int c, int dist) { | |
int last = 0; int cows = 1; | |
for(int i = 1; i < n; i++) { | |
if(a[i]-a[last] >= dist) { |
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
//http://coj.uci.cu/24h/problem.xhtml?abb=2534 | |
#include <cstdio> | |
#include <algorithm> | |
#include <cstring> | |
#include <vector> | |
using namespace std; | |
int main() { |
OlderNewer