ACM基础练习
基础练习
尒轩窗
这个作者很懒,什么都没留下…
展开
-
E
DescriptionOne measure of ``unsortedness'' in a sequence is the number of pairs of entries that are out of order with respect to each other. For instance, in the letter sequence ``DAABEC'', this m原创 2017-03-19 08:48:15 · 237 阅读 · 0 评论 -
T
DescriptionGiven positive integers B and N, find an integer A such that AN is as close as possible to B. (The result A is an approximation to the Nth root of B.) Note that AN may be less than, equ原创 2017-03-14 10:59:03 · 256 阅读 · 0 评论 -
H
Description In the 22nd Century, scientists have discovered intelligent residents live on the Mars. Martians are very fond of mathematics. Every year, they would hold an Arithmetic Contest on Mar原创 2017-03-14 13:25:10 · 271 阅读 · 0 评论 -
X
DescriptionGiven a list of phone numbers, determine if it is consistent in the sense that no number is the prefix of another. Let's say the phone catalogue listed these numbers:- Emergency 911-原创 2017-03-14 19:13:00 · 236 阅读 · 0 评论 -
Y
DescriptionThe look and say sequence is defined as follows. Start with any string of digits as the first element in the sequence. Each subsequent element is defined from the previous one by "verba原创 2017-03-14 19:52:37 · 229 阅读 · 0 评论 -
Z
DescriptionWhen a Little White meets another Little White:Little White A: (Surprised) !Little White B: ?Little White A: You Little White know "SHDC"? So unbelievable!Little White B: You ar原创 2017-03-14 21:21:13 · 242 阅读 · 0 评论 -
W
DescriptionTom's Meadow Tom has a meadow in his garden. He divides it into N * M squares. Initially all the squares were covered with grass. He mowed down the grass on some of the squares an原创 2017-03-15 14:08:23 · 221 阅读 · 0 评论 -
Q
DescriptionGiven a list of monetary amounts in a standard format, please calculate the total amount.We define the format as follows:1. The amount starts with '$'.2. The amount could have a l原创 2017-03-16 22:05:24 · 296 阅读 · 0 评论 -
S
DescriptionMessage queue is the basic fundamental of windows system. For each process, the system maintains a message queue. If something happens to this process, such as mouse click, text change,原创 2017-03-17 10:44:04 · 188 阅读 · 0 评论 -
V
DescriptionJim is fond of reading books, and he has so many books that sometimes it's hard for him to manage them. So he is asking for your help to solve this problem.Only interest in the name,原创 2017-03-13 19:05:15 · 210 阅读 · 0 评论 -
U
DescriptionMike is very lucky, as he has two beautiful numbers, 3 and 5. But he is so greedy that he wants infinite beautiful numbers. So he declares that any positive number which is dividable by原创 2017-03-13 13:02:27 · 235 阅读 · 0 评论 -
J
DescriptionYou may have heard of the book '2001 - A Space Odyssey' by Arthur C. Clarke, or the film of the same name by Stanley Kubrick. In it a spaceship is sent from Earth to Saturn. The crew is原创 2017-03-10 12:10:27 · 251 阅读 · 0 评论 -
L
DescriptionIn most languages, text is written from left to right. However, there are other languages where text is read and written from right to left. As a first step towards a program that autom原创 2017-03-10 21:44:39 · 281 阅读 · 0 评论 -
M
DescriptionAs part of an arithmetic competency program, your students will be given randomly generated lists of from 2 to 15 unique positive integers and asked to determine how many items in each原创 2017-03-11 13:19:57 · 194 阅读 · 0 评论 -
K
DescriptionLittle Bob likes playing with his box of bricks. He puts the bricks one upon another and builds stacks of different height. ``Look, I've built a wall!'', he tells his older sister Alice原创 2017-03-11 15:10:39 · 258 阅读 · 0 评论 -
O
DescriptionContest 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原创 2017-03-11 16:25:30 · 191 阅读 · 0 评论 -
P
DescriptionFatMouse prepared M pounds of cat food, ready to trade with the cats guarding the warehouse containing his favorite food, JavaBean.The warehouse has N rooms. The i-th room contains J[原创 2017-03-11 17:58:30 · 293 阅读 · 0 评论 -
N
DescriptionThe Antique Comedians of Malidinesia prefer comedies to tragedies. Unfortunately, most of the ancient plays are tragedies. Therefore the dramatic advisor of ACM has decided to transfigu原创 2017-03-11 15:01:22 · 203 阅读 · 0 评论 -
B
DescriptionWe all know that FatMouse doesn't speak English. But now he has to be prepared since our nation will join WTO soon. Thanks to Turing we have computers to help him.Input Specification原创 2017-03-12 21:11:51 · 283 阅读 · 0 评论 -
R
DescriptionPrime Number Definition An integer greater than one is called a prime number if its only positive divisors (factors) are one and itself. For instance, 2, 11, 67, 89 are prime numbers原创 2017-03-17 12:32:32 · 237 阅读 · 0 评论