上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 69 下一页

2025年11月23日

1088. Rational Arithmetic (20)

摘要: #include <iostream> using namespace std; long long getsame(long long a, long long b) { if(b != 0) { return getsame(b, a % b); } else { return a; } } v 阅读全文

posted @ 2025-11-23 17:20 王景迁 阅读(3) 评论(0) 推荐(0)

1087. All Roads Lead to Rome (30)

摘要: #include <iostream> #include <vector> #include <string.h> using namespace std; struct node { int next, cost; }; vector<node> v[27000]; vector<int> pat 阅读全文

posted @ 2025-11-23 17:20 王景迁 阅读(4) 评论(0) 推荐(0)

1086. Tree Traversals Again (25)

摘要: #include <iostream> #include <stack> using namespace std; struct node { int lchild, rchild, key; }tree[40]; int pre[40], in[40], r = 1, first = 1; int 阅读全文

posted @ 2025-11-23 17:20 王景迁 阅读(4) 评论(0) 推荐(0)

1085. Perfect Sequence (25)

摘要: #include <iostream> #include <algorithm> using namespace std; long long num[100010]; int getindex(int low, int high, long long goal) { int mid; while( 阅读全文

posted @ 2025-11-23 17:19 王景迁 阅读(3) 评论(0) 推荐(0)

1084. Broken Keyboard (20)

摘要: #include <iostream> #include <string.h> using namespace std; int flag[130]; void higherchar(char &ch) { if(ch >= 'a' && ch <= 'z') { ch -= 32; } } int 阅读全文

posted @ 2025-11-23 17:19 王景迁 阅读(4) 评论(0) 推荐(0)

1083. List Grades (25)

摘要: #include <iostream> using namespace std; struct node { char name[20], id[20]; }stu[110]; int flag[110]; int main() { int n; scanf("%d", &n); int i, gr 阅读全文

posted @ 2025-11-23 17:19 王景迁 阅读(3) 评论(0) 推荐(0)

1082. Read Number in Chinese (25)

摘要: #include <iostream> #include <string.h> using namespace std; int first = 1; void setfirst() { if(first == 1) { first = 0; } else { printf(" "); } } in 阅读全文

posted @ 2025-11-23 17:18 王景迁 阅读(5) 评论(0) 推荐(0)

1081. Rational Sum (20)

摘要: #include <iostream> using namespace std; long long getsame(long long a, long long b) { if(b != 0) { return getsame(b, a % b); } else { return a; } } v 阅读全文

posted @ 2025-11-23 17:18 王景迁 阅读(4) 评论(0) 推荐(0)

1080. Graduate Admission (30)

摘要: #include <iostream> #include <algorithm> #include <vector> using namespace std; struct node { int id, ge, gi, choice[5]; double finalgrade; }stu[40010 阅读全文

posted @ 2025-11-23 17:18 王景迁 阅读(3) 评论(0) 推荐(0)

1079. Total Sales of Supply Chain (25)

摘要: #include <iostream> #include <queue> #include <vector> using namespace std; double p, r, res, amount[100010]; queue<int> q; vector<int> v[100010]; voi 阅读全文

posted @ 2025-11-23 17:17 王景迁 阅读(2) 评论(0) 推荐(0)

上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 69 下一页

导航