摘要: 1 #include 2 #include 3 #include 4 #include 5 #include 6 #include 7 using namespace std; 8 9 int main(int argc,char *argv[]) 10 { 11 int s; 12 struct sockaddr_in server_addr; 13 ... 阅读全文
posted @ 2018-10-17 18:52 wa小怪兽 阅读(1014) 评论(0) 推荐(0) 编辑
摘要: Server: Client: 阅读全文
posted @ 2018-10-17 17:58 wa小怪兽 阅读(444) 评论(0) 推荐(0) 编辑
摘要: #include #include using namespace std; int m,k,ans; char s[1010][1010]; int vis[1010][1010]; bool check(int x,int y) { for(int i=0;i=0&&x=0&&vis[x][y]==0&&s[x][y]=='#'&&check(x,y)) { ... 阅读全文
posted @ 2018-09-11 20:42 wa小怪兽 阅读(104) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std; long long quick(long long a,long long b,int c) { int ans=1; a=a%c; while(b!=0) { if(b&1) ans=(ans*a)%c; b>>=1; a=(a*a)%c; }... 阅读全文
posted @ 2018-09-11 18:55 wa小怪兽 阅读(84) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include using namespace std; int main() { int t,n,x; long long maxn,all; scanf("%d",&t); while(t--) { maxn=0;all=0; scanf("%d",&n... 阅读全文
posted @ 2018-09-09 21:50 wa小怪兽 阅读(71) 评论(0) 推荐(0) 编辑
摘要: #include #include #include using namespace std; int m,n; char s[110][110]; int vis[110][110]; void dfs(int x,int y,int v) { if(x=0&&y=0&&s[x][y]=='@'&&vis[x][y]==0) { vis[x][y]=... 阅读全文
posted @ 2018-09-09 21:32 wa小怪兽 阅读(125) 评论(0) 推荐(0) 编辑
摘要: “今年暑假不AC?” “是的。” “那你干什么呢?” “看世界杯呀,笨蛋!” “@#$%^&*%...” 确实如此,世界杯来了,球迷的节日也来了,估计很多ACMer也会抛开电脑,奔向电视了。 作为球迷,一定想看尽量多的完整的比赛,当然,作为新时代的好青年,你一定还会看一些其它的节目,比如新闻联播(永 阅读全文
posted @ 2018-07-24 16:33 wa小怪兽 阅读(150) 评论(0) 推荐(0) 编辑
摘要: 东北联赛上有一道题,数据范围是2^60,当时不记得long long的范围,于是写了一个程序试了一下,把队友带入了一个大数的大坑QAQ(蠢哭)。 当时写的代码是这样的: 程序输出0。 于是我就把队友带入了大数的大坑一去不回QAQ。 后来发现1和60都是int类型的,应该加上一个强制类型转换QAQ。好 阅读全文
posted @ 2018-06-20 12:00 wa小怪兽 阅读(160) 评论(0) 推荐(0) 编辑
摘要: 还没测试完善。。 1 #ifndef SQLITE_H 2 #define SQLITE_H 3 4 #include <QSqlDatabase> 5 #include <QSqlQuery> 6 #include <QSqlRecord> 7 #include <QSqlError> 8 #in 阅读全文
posted @ 2018-06-09 15:52 wa小怪兽 阅读(2629) 评论(0) 推荐(0) 编辑
摘要: #include #include using namespace std; int f[20000],n; struct node { int u,v,val; bool operator >n) { ans=0; k=(n*(n-1))/2; for(int i=1;i>e[i].u>>e[i].v>>e[i].v... 阅读全文
posted @ 2018-02-12 15:00 wa小怪兽 阅读(162) 评论(0) 推荐(0) 编辑