2012年5月16日
摘要: Barn RepairIt was a dark and stormy night that ripped the roof and gates off the stalls that hold Farmer John's cows. Happily, many of the cows were on vacation, so the barn was not completely full.The cows spend the night in stalls that are arranged adjacent to each other in a long line. Some s 阅读全文
posted @ 2012-05-16 00:20 Zee、 阅读(186) 评论(0) 推荐(0) 编辑
  2012年5月14日
摘要: Mixing MilkSince milk packaging is such a low margin business, it is important to keep the price of the raw product (milk) as low as possible. Help Merry Milk Makers get the milk they need in the cheapest possible manner.The Merry Milk Makers company has several farmers from which they may buy milk, 阅读全文
posted @ 2012-05-14 20:55 Zee、 阅读(166) 评论(0) 推荐(0) 编辑
  2012年5月12日
摘要: 昨天一天没有接触电脑,就只是下午开了一个关于我们计算机专业分流的会。表示不解的是,既然领导把软件工程说的那么那么好,几乎没有比计算机科学差的,却只收30人。。 想想过去的这一周还挺不错的,每天都会坐在实验室做我的USACO ,边做边学,现在遇到问题不习惯去问别人了,因为不希望看到别人自傲或者厌恶的回答,我甚至觉得自己在网上看看资料,看看论坛,学到的比别人教我的更加踏实。 每天晚上回来会看一些ACM中基本用不到的C++面向对象啊什么的。感觉这些东西也不错,虽然ACM让我们了解甚至会使用了一些算法,但是靠这些东西才能真正去做一些东西出来,想自己编个小游戏,想自己编个什么小项目,就像上学期的... 阅读全文
posted @ 2012-05-12 14:32 Zee、 阅读(237) 评论(0) 推荐(1) 编辑
  2012年5月10日
摘要: Dual PalindromesMario Cruz (Colombia) & Hugo Rickeboer (Argentina)A number that reads the same from right to left as when read from left to right is called a palindrome. The number 12321 is a palindrome; the number 77778 is not. Of course, palindromes have neither leading nor trailing zeroes, so 阅读全文
posted @ 2012-05-10 21:33 Zee、 阅读(230) 评论(0) 推荐(0) 编辑
摘要: Palindromic SquaresRob KolstadPalindromes are numbers that read the same forwards as backwards. The number 12321 is a typical palindrome.Given a number base B (2 <= B <= 20 base 10), print all the integers N (1 <= N <= 300 base 10) such that the square of N is palindromic when expressed 阅读全文
posted @ 2012-05-10 18:07 Zee、 阅读(391) 评论(0) 推荐(0) 编辑
  2012年5月9日
摘要: 今天做USACO 用到了文件的操作。 之前做USACO只是格式化的些 写 freopen("xxx.in","r",stdin) 和"freopen("xxx.out","w",stdout)" 百度百科上是这么介绍的: 函数名: freopen 功 能: 替换一个流,或者说重新分配文件指针,实现重定向。如果stream流已经打开,则先关闭该流。如果该流已经定向,则freopen将会清除该定向。此函数一般用于将一个指定的文件打开一个预定义的流:标准输入、标准输出或者标准出错。 用 法: FILE 阅读全文
posted @ 2012-05-09 22:56 Zee、 阅读(3983) 评论(1) 推荐(0) 编辑
摘要: TransformationsA square pattern of size N x N (1 <= N <= 10) black and white square tiles is transformed into another square pattern. Write a program that will recognize the minimum transformation that has been applied to the original pattern given the following list of possible transformation 阅读全文
posted @ 2012-05-09 12:07 Zee、 阅读(168) 评论(0) 推荐(0) 编辑
  2012年5月8日
摘要: Milking CowsThree farmers rise at 5 am each morning and head for the barn to milk three cows. The first farmer begins milking his cow at time 300 (measured in seconds after 5 am) and ends at time 1000. The second farmer begins at time 700 and ends at time 1200. The third farmer begins at time 1500 a 阅读全文
posted @ 2012-05-08 11:32 Zee、 阅读(263) 评论(0) 推荐(0) 编辑
摘要: Broken NecklaceYou have a necklace of N red, white, or blue beads (3<=N<=350) some of which are red, others blue, and others white, arranged at random. Here are two examples for n=29: 1 2 1 2 r b b r b r r b r... 阅读全文
posted @ 2012-05-08 09:49 Zee、 阅读(193) 评论(0) 推荐(0) 编辑
摘要: 貌似好久没有写博客了,之前用的是CSDN,写过十几篇,不过还是感觉那个太过于官方话,相比之下我还是喜欢博客园的界面。 现在也已经大二,ACM还是搞的一头雾水,上次去武大参加比赛也打酱油,被虐的一塌糊涂。 为了勉励自己,记录自己的学习,我决定坚持写博客,之前的CSDN我不要了,就从这里开始,就从这里开始。我的ACM征程再起起航! 我对自己做一下要求: 1.坚持写博客,就算当天没有做出题目,总要把学到的写记录下。 不要想以前那样三分钟热度,写一段时间就又懒得写了。 2.坚持每天学习,不要因为今天星期六或者今天星期天就找个借口出去放松,青春由不得我们懈怠放松陪。 3.遇到问题... 阅读全文
posted @ 2012-05-08 09:42 Zee、 阅读(166) 评论(0) 推荐(0) 编辑