摘要:
#include<iostream> using namespace std; int GetMaxNum(int a[],int n) //求最大字段和 { int i,sum=0,maxsum=0; maxsum|=1<<31; for(i=1;i<=n;i++) { sum+=a[i]; if 阅读全文
摘要:
#include<iostream> using namespace std; char s1[105],s2[105]; int val[5][5]={ {5,-1,-2,-1,-3}, {-1,5,-3,-2,-4}, {-2,-3,5,-2,-2}, {-1,-2,-2,5,-1}, {-3, 阅读全文
摘要:
#include<cstdio> #include<iostream> #include<cstring> using namespace std; int main(){ int y,m,d; int t; scanf("%d",&t); while(t--){ scanf("%d%d%d",&y 阅读全文
摘要:
#include <stdio.h> #include <string.h> #include <algorithm> using namespace std; int n,k,dp[105][105],a[105][105]; int to[4][2] = {1,0,-1,0,0,1,0,-1}; 阅读全文
摘要:
#include<iostream> #include<cmath> using namespace std; struct Point { double x,y; }; double dis_sq(const Point& a,const Point& b) //距离平方 { return (a. 阅读全文