http://www.patest.cn/contests/pat-a-practise/1023 1 n = input() 2 n2 = n << 1 3 list_n = sorted(list(str(n))) 4 list_n2 = sorted(list(str(n * 2))) 5 i... Read More
posted @ 2015-08-03 18:19 ACSeed Views(164) Comments(0) Diggs(0)
http://www.patest.cn/contests/pat-a-practise/1041 1 #include 2 #include 3 int num[11000]; 4 int bet_num[100000 + 5]; 5 6 int main() { 7 int n; 8 ... Read More
posted @ 2015-08-03 17:53 ACSeed Views(112) Comments(0) Diggs(0)
http://www.patest.cn/contests/pat-a-practise/1084 1 #include 2 3 using namespace std; 4 5 int hash[256]; 6 char s1[100]; 7 char s2[100]; 8 9 void t... Read More
posted @ 2015-08-03 17:39 ACSeed Views(139) Comments(0) Diggs(0)
http://www.patest.cn/contests/pat-a-practise/1015#include #includeusing namespace std;int n, d;char s[1000];int toRadix(int x, int d) { int result ... Read More
posted @ 2015-08-03 14:35 ACSeed Views(108) Comments(0) Diggs(0)
http://www.patest.cn/contests/pat-a-practise/1031 1 #include 2 #include 3 4 using namespace std; 5 6 char s[1000]; 7 8 int main() { 9 scanf("%s... Read More
posted @ 2015-08-03 14:07 ACSeed Views(172) Comments(0) Diggs(0)
http://www.patest.cn/contests/pat-a-practise/1014 1 #include 2 #include 3 #include 4 #include 5 #include 6 7 using namespace std; 8 9 const int MAXN... Read More
posted @ 2015-08-03 13:00 ACSeed Views(135) Comments(0) Diggs(0)
>参考 http://wiki.ubuntu.org.cn/Gedit%E4%B8%AD%E6%96%87%E4%B9%B1%E7%A0%81##11.10以后>1.运行dconf-editor2.展开/org/gnome/gedit/preferences/encodings3.auto-dete... Read More
posted @ 2015-08-01 10:45 ACSeed Views(157) Comments(0) Diggs(0)
http://www.patest.cn/contests/pat-a-practise/1050简单题 1 #include 2 #include 3 4 #define MAXN 11000 5 int hash[256]; 6 7 char s1[MAXN]; 8 char s2[MAXN... Read More
posted @ 2015-08-01 00:49 ACSeed Views(145) Comments(0) Diggs(0)
今天做PAT1057, 感觉平衡二叉树可以搞过, 学习了下treap下面以PAT1057为例 (参考liuruja的书),代码记在这里备忘#Treap> Treap可以动态维护一个有序表,支持在O(logn)的时间内完成插入一个元素,删除一个元素和查找第k大元素> Treap是一种平衡化的二叉搜索树... Read More
posted @ 2015-08-01 00:10 ACSeed Views(144) Comments(0) Diggs(0)
http://www.patest.cn/contests/pat-a-practise/1057treap 求第k大的数 1 #include 2 #include 3 #include 4 #include 5 #include 6 7 using namespace std; ... Read More
posted @ 2015-07-31 22:57 ACSeed Views(254) Comments(0) Diggs(0)