摘要: printf("%.6f\n",n*n*(pi/2.0-1.0)); // no printf("%.6f\n",(double)n*n*(pi/2.0-1.0)); // yes printf("%.6f\n",(pi/2.0-1.0)*n*n); //yes 阅读全文
posted @ 2020-06-26 17:50 特立独行的猪猪 阅读(131) 评论(0) 推荐(0) 编辑
摘要: 裸题:https://ac.nowcoder.com/acm/contest/5929/B #include<bits/stdc++.h> using namespace std; typedef long long ll; const int inf = 0x3f3f3f3f; int n; st 阅读全文
posted @ 2020-06-26 14:56 特立独行的猪猪 阅读(1363) 评论(0) 推荐(0) 编辑
摘要: 裸题:https://www.luogu.com.cn/problem/P1908 逆序对的个数等于在朴素稳定排序情况下,相邻数交换的次数。 使用归并排序求解 对于ans += mid-ii+1 的理解: #include<bits/stdc++.h> using namespace std; ty 阅读全文
posted @ 2020-06-26 11:04 特立独行的猪猪 阅读(107) 评论(0) 推荐(0) 编辑