- 博客(7)
- 收藏
- 关注
原创 Educational Codeforces Round 117
A. Distance分析:|x+y|为奇数不行,否则暴力#include "bits/stdc++.h"using namespace std;int main(){ //freopen("in.txt","r",stdin); int T; ios::sync_with_stdio(false); cin>>T; while(T--){ int x,y; cin>>x>>y; if((a
2021-12-05 22:03:13 326
原创 Educational Codeforces Round 116
A. AB Balance分析:只要第一个和最后一个相同,均满足#include "bits/stdc++.h"using namespace std;const int maxn=1000+1;string s[maxn];int main(){ //freopen("in.txt","r",stdin); int n; ios::sync_with_stdio(false); cin>>n; for(int i=1;i<=n;i++
2021-11-22 23:55:29 358
原创 MIT6.S081 xv6: Operating System interface
Processes and memorysystem call系统调用 描述int fork() 创建一个进程,返回子进程的PIDint exit(int status) 终止当前进程,status传递给wait()。不会返回int kill(int pid) 终止给定PID的进程,成功返回0,失败返回-1int getpid() 返回当前进程的PIDint sleep(int n) 睡眠n个时钟周期int exec(char *file, char *argv[]) 通过给定参数加载并执行
2021-11-15 04:42:42 2280
原创 MIT6.S081 Lab1:Unix utilities
sleepImplement the UNIX program sleep for xv6; your sleep should pause for a user-specified number of ticks. A tick is a notion of time defined by the xv6 kernel, namely the time between two interrupts from the timer chip. Your solution should be in the f
2021-11-10 23:08:50 512
原创 [kuangbin带你飞]专题一 简单搜索
A - 棋盘问题分析:DFS+回溯#include "cstdio"#include "cstring"#include "iostream"using namespace std;const int maxn = 10;char s[maxn][maxn];int vis[maxn];int n, k, cnt;void dfs(int cur, int count) { if (count == k) { cnt++; return; } if (cur
2021-10-08 22:47:31 76
原创 The 2021 Sichuan Provincial Collegiate Programming Contest
今年年初就和深爷策划去打星参加一场ICPC,正好今年5月底公司多送了2天年假,于是找来了还在电科读研的师弟林喵喵,组了一支退役旅游队。chenjb的这套题出得蛮好,总体来说题目难度不大,但很多意思题目却很有意思。本老年人成为全场最坑,感谢喵喵和深爷不嫌我菜,带我玩。最终我们只通过了7题,果然退役很久之后越来越菜。结果不是很满意吧,但是能再次去打onsite,真的很开心,彷佛又回到了20岁QAQ...
2021-06-12 00:55:01 1577 3
原创 Contest 2050 and Codeforces Round #718 (Div. 1 + Div. 2)
A. Sum of 2050#include <bits/stdc++.h>using namespace std;typedef long long LL;int T;int main(){ scanf("%d",&T); while(T--){ LL n; scanf("%lld",&n); if(n%2050){ printf("-1\n"); }else{
2021-05-20 23:22:42 154
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人