随笔分类 -  水题

Memory and Trident(CodeForces 712B)
摘要:Description Memory is performing a walk on the two-dimensional plane, starting at the origin. He is given a string s with his directions for motion: A 阅读全文
posted @ 2018-10-05 17:35 Baiyi_destroyer 阅读(146) 评论(0) 推荐(0)
Romaji (CodeForces - 1008A )
摘要:Vitya has just started learning Berlanese language. It is known that Berlanese uses the Latin alphabet. Vowel letters are "a", "o", "u", "i", and "e". 阅读全文
posted @ 2018-10-01 16:45 Baiyi_destroyer 阅读(373) 评论(0) 推荐(0)
Sorting a Three-Valued Sequence(三值的排序)
摘要:Description 排序是一种很频繁的计算任务。现在考虑最多只有三值的排序问题。一个实际的例子是,当我们给某项竞赛的优胜者按金银铜牌序的时候。 在这个任务中可能的值只有三种1,2和3。我们用交换的方法把他排成升序的。 写一个程序计算出,给定的一个1,2,3组成的数字序列,排成升序所需的最少交换次 阅读全文
posted @ 2018-09-09 09:02 Baiyi_destroyer 阅读(152) 评论(0) 推荐(0)
Factorials 阶乘
摘要:Description N的阶乘写作N!表示小于等于N的所有正整数的乘积。阶乘会很快的变大,如13!就必须用32位整数类型来存储,70!即使用浮点数也存不下了。你的任务是找到阶乘最后面的非零位。举个例子,5!=1*2*3*4*5=120所以5!的最后面的非零位是2,7!=1*2*3*4*5*6*7= 阅读全文
posted @ 2018-08-30 16:02 Baiyi_destroyer 阅读(197) 评论(0) 推荐(0)