上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 31 下一页
摘要: # A. Grasshopper on a Line ```cpp #include using namespace std; #define int long long void solve(){ int x , k; cin >> x >> k; if( x % k == 0 ){ cout > 阅读全文
posted @ 2023-05-30 21:45 PHarr 阅读(18) 评论(0) 推荐(1) 编辑
摘要: # A. Musical Puzzle ```cpp #include using namespace std; void solve(){ int n; string s; cin >> n >> s; set cnt; for( int i = 0 ; i + 1 > t; while( t - 阅读全文
posted @ 2023-05-29 17:52 PHarr 阅读(33) 评论(0) 推荐(0) 编辑
摘要: # A. Drill Wood to Make Fire ```cpp #include using namespace std; #define int long long void solve(){ int n , s , v; cin >> n >> s >> v; cout = n) > t 阅读全文
posted @ 2023-05-25 21:27 PHarr 阅读(404) 评论(0) 推荐(0) 编辑
摘要: # A - Attack ```cpp #include using namespace std; #define int long long int32_t main() { int a , b; cin >> a >> b; cout using namespace std; #define i 阅读全文
posted @ 2023-05-25 17:45 PHarr 阅读(29) 评论(0) 推荐(0) 编辑
摘要: # A. 签到啦 排序做就好了 ```cpp #include using namespace std; #define int long long void solve(){ int n , w , res = 0; cin >> n >> w; vector a(n); for( auto & 阅读全文
posted @ 2023-05-22 22:28 PHarr 阅读(142) 评论(0) 推荐(0) 编辑
摘要: # A - Overall Winner ```cpp #include using namespace std; #define int long long int32_t main(){ ios::sync_with_stdio(false); cin.tie(nullptr) , cout.t 阅读全文
posted @ 2023-05-22 15:27 PHarr 阅读(21) 评论(0) 推荐(0) 编辑
摘要: # C. Darkness I 首先根据短边放一条对角线,然后往后每隔一列只放一个即可。 ```cpp #include using namespace std; #define int long long int32_t main() { ios::sync_with_stdio(false), 阅读全文
posted @ 2023-05-19 20:25 PHarr 阅读(80) 评论(0) 推荐(0) 编辑
摘要: # A. 小水獭游河南 a的长度小于 26,所以直接暴力枚举暴力判断。 ```cpp #include using namespace std; void solve() { string s; cin >> s; if (s.size() == 1) { cout cnt; for (int i 阅读全文
posted @ 2023-05-19 20:22 PHarr 阅读(72) 评论(0) 推荐(0) 编辑
摘要: A. 小斧头 $O(N^3)$ 20 points 暴力枚举左右端点,然后暴力求区间最值 #include <bits/stdc++.h> using namespace std; #define int long long int read(){...} int32_t main() { int 阅读全文
posted @ 2023-05-08 19:53 PHarr 阅读(41) 评论(0) 推荐(0) 编辑
摘要: A. Love Story #include<bits/stdc++.h> using namespace std; #define int long long int read() { int x = 0, f = 1, ch = getchar(); while ((ch < '0' || ch 阅读全文
posted @ 2023-05-08 19:53 PHarr 阅读(35) 评论(0) 推荐(0) 编辑
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 31 下一页