A - Good ol' Numbers Coloring 直接判断两个数是否互质 #include <stdio.h> #include <iostream> #include <cstring> #include <algorithm> #include <cmath> #include <qu ...
分类:
其他好文 时间:
2019-11-05 17:02:02
阅读次数:
110
链接: https://codeforces.com/contest/1245/problem/A 题意: Consider the set of all nonnegative integers: 0,1,2,…. Given two integers a and b (1≤a,b≤104). W ...
分类:
其他好文 时间:
2019-11-05 13:49:03
阅读次数:
110
传送门 ?题意 给出 n 个人,m 场比赛; 这 m 场比赛,每一场比赛中的对决的两人,一个属于 "good player" 另一个属于 "bad player"; 给出你 x 个已经确定的"good player" 和 y 个已经确定的 "bad player"。 问是否可以将这 n 个人划分成两 ...
分类:
其他好文 时间:
2019-11-03 13:11:04
阅读次数:
76
#重复输出字符串 print('hello'*2) #索引、切片取字符串中的某值 print('helloworld'[-3:]) #格式字符串 % print("%s is a good man!"%'csun') #字符串拼接,重点,join方法 a='123' b='abc' c='。。。'.... ...
分类:
其他好文 时间:
2019-10-31 10:44:34
阅读次数:
102
[toc] 电脑重装系统注意点 尽可能快速恢复你熟悉的 windows 请在 重装系统前 把下面这些步骤做好(对应的有些后续步骤是等重装完系统后再做的) 基本使用场景 本文是为 后快速恢复之前的使用习惯而写的 尽可能少的影响之前的使用习惯,快速找到熟悉的 feel ~ 备注:重装系统时,计算机名千万 ...
分类:
编程语言 时间:
2019-10-28 09:13:00
阅读次数:
281
https://codeforces.com/problemset/problem/1249/C2 C2. Good Numbers (hard version) time limit per test 2 seconds time limit per test memory limit per t ...
分类:
其他好文 时间:
2019-10-28 00:57:35
阅读次数:
103
good numbers easy version 输入值n一直除3至0,在这个过程中只要n % 3 == 2就说明n不是good number,因为2 == 3^0 + 3^0 ...
分类:
其他好文 时间:
2019-10-28 00:35:07
阅读次数:
140
题目链接http://codeforces.com/contest/1249/problem/C2。这是道进制转换题,我们的目的是找到最小的一个每个位都是1的三进制数来表示一个十进制数n。做法是,先将n转换为一个三进制数,然后对当前位加上低位的进位大于等于2的位置0并进位,这一步需要注意的是,当前位 ...
分类:
其他好文 时间:
2019-10-27 12:27:26
阅读次数:
79
首先, bash中命令执行成功返回状态码 0, 失败返回非0状态码(以下$是终端提示符) $ true; echo $? 0 $ false; echo $? 1 1. while $ while true; do echo good; break; done good $ while [ 1 eq ...
分类:
其他好文 时间:
2019-10-27 01:17:39
阅读次数:
130
Born on the wrong side of the ocean 生在海的逆流一端 With all the tides against you 潮汐日夜向你侵袭 You never thought you'd be much good for anyone 你从未想过自己对他人有何种非凡意义 ...
分类:
其他好文 时间:
2019-10-25 09:39:03
阅读次数:
98