码迷,mamicode.com
首页 >  
搜索关键字:being a good boy in    ( 3225个结果
CF1245 A. Good ol' Numbers Coloring(java与gcd)
题意:给定数字A和数字B,问是否满足gcd(A,B)==1。 思路:可以直接写函数gcd。也可以用大数自带的gcd功能。 代码1: /* @author nimphy @create 2019-11-06-12:07 about: */ import java.io.*; import java.u ...
分类:编程语言   时间:2019-11-06 13:09:49    阅读次数:87
codeforces - 1245 (div2)
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
Codeforces Round #597 (Div. 2) A. Good ol' Numbers Coloring
链接: 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
Codeforces Round #597 (Div. 2) E. Hyakugoku and Ladders 概率dp
E. Hyakugoku and Ladders Hyakugoku has just retired from being the resident deity of the South Black Snail Temple in order to pursue her dream of beco ...
分类:其他好文   时间:2019-11-03 18:30:19    阅读次数:120
HDU 5971"Wrestling Match"(二分图染色)
传送门 ?题意 给出 n 个人,m 场比赛; 这 m 场比赛,每一场比赛中的对决的两人,一个属于 "good player" 另一个属于 "bad player"; 给出你 x 个已经确定的"good player" 和 y 个已经确定的 "bad player"。 问是否可以将这 n 个人划分成两 ...
分类:其他好文   时间:2019-11-03 13:11:04    阅读次数:76
Linux03 /Linux基本命令
Linux03 /Linux基本命令 1.Linux命令行的组成结构 2.Linux系统命令操作语法格式 命令 空格 参数 空格 【文件或路径】需要处理的内容 rm rf /tmp/ ls la /home 3.创建一个目录 /boy 4.查看目录 /boy 5.改变当前的目录/位置 6.打印当前工 ...
分类:系统相关   时间:2019-11-01 20:39:00    阅读次数:138
字符串,各种方法!
#重复输出字符串 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
Good number(3进制)
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
Div3 C good number easy version
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
Codeforces--C2. Good Numbers (hard version)
题目链接http://codeforces.com/contest/1249/problem/C2。这是道进制转换题,我们的目的是找到最小的一个每个位都是1的三进制数来表示一个十进制数n。做法是,先将n转换为一个三进制数,然后对当前位加上低位的进位大于等于2的位置0并进位,这一步需要注意的是,当前位 ...
分类:其他好文   时间:2019-10-27 12:27:26    阅读次数:79
3225条   上一页 1 ... 23 24 25 26 27 ... 323 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!