2013年4月18日
摘要: give you two number A and B,you should output the result of A+B. 阅读全文
posted @ 2013-04-18 09:16 P,Z 阅读(196) 评论(0) 推荐(0) 编辑
摘要: 一个简单问题,在一串数中找出第N大的数 阅读全文
posted @ 2013-04-18 09:04 P,Z 阅读(282) 评论(0) 推荐(0) 编辑
  2013年4月17日
摘要: lcy gives a hard puzzle to feng5166,lwg,JGShining and Ignatius: gave a and b,how to know the a^b.everybody objects to this BT problem,so lcy makes the problem easier than begin. this puzzle describes that: gave a and b,how to know the a^b's the last digit number.But everybody is too lazy to slove this problem,so they remit to you who is wise. 阅读全文
posted @ 2013-04-17 00:30 P,Z 阅读(320) 评论(0) 推荐(0) 编辑
摘要: As we know , we always use the decimal system in our common life, even using the computer. If we want to calculate the value that 3 plus 9, we just import 3 and 9.after calculation of computer, we will get the result of 12. But after learning ,we know that the computer will do the calculation as the following steps: 1 computer change the 3 into binary formality like 11; 2 computer change the 9 into binary formality like 1001; 3 computer plus the two number and ge 阅读全文
posted @ 2013-04-17 00:03 P,Z 阅读(266) 评论(4) 推荐(0) 编辑
  2013年4月16日
摘要: In the new year party, everybody will get a "special present".Now it's your turn to get your special present, a lot of presents now putting on the desk, and only one of them will be yours.Each present has a card number on it, and your present's card number will be the one that different from all the others, and you can assume that only one number appear odd times.For example, there are 5 present, and their card numbers are 1, 2, 3, 2, 1.so your present will be the one with the card number of 3, 阅读全文
posted @ 2013-04-16 21:17 P,Z 阅读(301) 评论(0) 推荐(0) 编辑
摘要: Larry graduated this year and finally has a job. He’s making a lot of money, but somehow never seems to have enough. Larry has decided that he needs to grab hold of his financial portfolio and solve his financing problems. The first step is to figure out what’s been going on with his money. Larry has his bank account statements and wants to see how much money he has. Help Larry by writing a program to take his closing balance from each of the past twelve months and calculate his average account 阅读全文
posted @ 2013-04-16 20:08 P,Z 阅读(223) 评论(0) 推荐(0) 编辑
摘要: The Children’s Day has passed for some days .Has you remembered something happened at your childhood? I remembered I often played a game called hide handkerchief with my friends. Now I introduce the game to you. Suppose there are N people played the game ,who sit on the ground forming a circle ,everyone owns a box behind them .Also there is a beautiful handkerchief hid in a box which is one of the boxes . Then Haha(a friend of mine) is called to find the handkerchief. But he has a strange habi 阅读全文
posted @ 2013-04-16 19:50 P,Z 阅读(265) 评论(0) 推荐(0) 编辑
摘要: An inch worm is at the bottom of a well n inches deep. It has enough energy to climb u inches every minute, but then has to rest a minute before climbing again. During the rest, it slips down d inches. The process of climbing and resting then repeats. How long before the worm climbs out of the well? We'll always count a portion of a minute as a whole minute and if the worm just reaches the top of the well at the end of its climbing, we'll assume the worm makes it out. 阅读全文
posted @ 2013-04-16 19:01 P,Z 阅读(232) 评论(0) 推荐(0) 编辑
  2013年4月12日
摘要: Most bicycle speedometers work by using a Hall Effect sensor fastened to the front fork of the bicycle. A magnet is attached to one of the spokes on the front wheel so that it will line up with the Hall Effect switch once per revolution of the wheel. The speedometer monitors the sensor to count wheel revolutions. If the diameter of the wheel is known, the distance traveled can be easily be calculated if you know how many revolutions the wheel has made. In addition, if the time it takes to comple 阅读全文
posted @ 2013-04-12 15:22 P,Z 阅读(394) 评论(0) 推荐(0) 编辑
  2013年4月9日
摘要: Contest time again! How excited it is to see balloons floating around. But to tell you a secret, the judges' favorite time is guessing the most popular problem. When the contest is over, they will count the balloons of each color and find the result. This year, they decide to leave this lovely job to you. 阅读全文
posted @ 2013-04-09 00:54 P,Z 阅读(483) 评论(0) 推荐(0) 编辑