2018USACO金级第二题(翻译)

合集下载

USACO 2018.12月铜组Bronze竞赛真题(中文)

USACO 2018.12月铜组Bronze竞赛真题(中文)

USACO2018D ECEMBER C ONTEST,B RONZEP ROBLEM1.M IXING M ILK农业,尤其是生产牛奶,是一个竞争激烈的行业。

Farmer John发现如果他不在牛奶生产工艺上有所创新,他的乳制品生意可能就会受到重创!幸运的是,Farmer John想出了一个好主意。

他的三头获奖的乳牛,Bessie、Elsie和Mildred,各自产奶的口味有些许不同,他打算混合这三种牛奶调制出完美的口味。

为了混合这三种不同的牛奶,他拿来三个桶,其中分别装有三头奶牛所产的奶。

这些桶可能有不同的容积,也可能并没有完全装满。

然后他将桶1的牛奶倒入桶2,然后将桶2中的牛奶倒入桶3,然后将桶3中的牛奶倒入桶1,然后再将桶1的牛奶倒入桶2,如此周期性地操作,共计进行100次(所以第100次操作会是桶1倒入桶2)。

当Farmer John将桶$a$中的牛奶倒入桶$b$时,他会倒出尽可能多的牛奶,直到桶$a$被倒空或是桶$b$被倒满。

请告诉Farmer John当他倒了100次之后每个桶里将会有多少牛奶。

输入格式(文件名:mixmilk.in):输入文件的第一行包含两个空格分隔的整数:第一个桶的容积$c_1$,以及第一个桶里的牛奶量$m_1$。

$c_1$和$m_1$均为正,并且不超过$10^9$。

第二和第三行类似地包含第二和第三个桶的容积和牛奶量。

输出格式(文件名:mixmilk.out):输出三行,给出倒了100次之后每个桶里的牛奶量。

输入样例:103114125输出样例:102在这个例子中,每倒一次之后每个桶里的牛奶量如下:初始状态:3451.桶1->2:0752.桶2->3:00123.桶3->1:10024.桶1->2:01025.桶2->3:0012(之后最后三个状态循环出现……)供题:Brian DeanUSACO2018D ECEMBER C ONTEST,B RONZEP ROBLEM2.T HE B UCKET L ISTFarmer John正在考虑改变他给奶牛挤奶的时候分配牛奶桶的方式。

2018-1USACO真题S2

2018-1USACO真题S2

O VERVIEW T RAINING C ONTESTS H ISTORY S TAFF R ESOURCESUSACO 2018 J ANUARY C ONTEST, S ILVERP ROBLEM 2. U SACO WFarmer John realizes that the income he receives from milk production is insufficient to fund thegrowth of his farm, so to earn some extra money, he launches a cow-rental service, which he calls"USACOW" (pronounced "Use-a-cow").Farmer John has N cows (1≤N≤100), each capable of producing some amount of milk every day.The M stores near FJ's farm (1≤M≤100) each offer to buy a certain amount of milk at a certainprice. Moreover, Farmer John's R (1≤R≤1000) neighboring farmers are each interested in renting acow at a certain price.Farmer John has to choose whether each cow should be milked or rented to a nearby farmer.Help him find the maximum amount of money he can make per day.INPUT FORMAT (file rental.in):The first line in the input contains N, M, and R. The next N lines each contain an integer ci(1≤ci≤1,000), indicating that Farmer John's i th cow can produce ci gallons of milk every day. Thenext M lines each contain two integers qi and pi (1≤qi, pi≤1,000), indicating that the i th store iswilling to buy up to qi gallons of milk for pi cents per gallon. Keep in mind that Farmer John cansell any amount of milk between zero and qi gallons to a given store. The next R lines eachcontain an integer ri (1≤ri≤1,000), indicating that one of Farmer John's neighbors wants to rent acow for ri cents per day.OUTPUT FORMAT (file rental.out):The output should consist of one line containing the maximum profit Farmer John can make perday by milking or renting out each of his cows. Note that the output might be too large to fit into astandard 32-bit integer, so you may need to use a larger integer type like a "long long" in C/C++.SAMPLE INPUT:5 3 46247110 252 1015 152508010040SAMPLE OUTPUT:725Farmer John should milk cows #1 and #4, to produce 13 gallons of milk. He should completely fillthe order for 10 gallons, earning 250 cents, and sell the remaining three gallon。

2018届金山区高考英语二模试卷和参考答案及听力原文

2018届金山区高考英语二模试卷和参考答案及听力原文

金山区2017 学年第二学期质量监控高三英语试卷(时间120 分钟,分值140 分)2018年4 月I. Listening ComprehensionSection ADirections: In Part A, you will hear ten short conversations between two speakers. At the end of each conversation, a question will be asked about what was said. The conversations and the questions will be spoken only once. After you hear a conversation and the question about it, read the four possible answers on your paper, and decide which one is the best answer to the question you have heard.1. A. For one week. B. For less than a week.C. For two weeks.D. Hard to say.2. A. Go to her sister ’s wedding ceremony. B. Stay at home.C. Go to George’s birthday party.D. Go to George ’s house-warming party.3. A. 50 dollars. B. 40 dollars. C. 60 dollars. D. 55 dollars.4. A. She feels bored with the idea. B. She thinks ballet is funny.C. She will not go with the man anyway.D. She shows interest in the show.5. A. Snowy. B. Sunny. C. Windy. D. Cloudy.6. A. She hasn’t seen Monet’s paintings for ten years.B. She hasn’t been to the museum for long.C. She has been interested in Monet’s paintings for ten years.D. She used to own one of Monet ’s paintings.7. A. Father and daughter. B. Friends.C. Husband and wife.D. Boss and his employee.8. A. The man is not interested in the game this weekend.B. The man is not interested in the team that will play this weekend.C. The man doesn’t want to mention the game.D. The man is not interested in watching any game.9. A. She would see Ellen at last.B. She saw Ellen for the last time not long ago.C. She has many people to see before Ellen.D. She wouldn ’t like to see Ellen at all.10. A. The woman is sorry for not being able to spend the holiday with the man.B. The man is a bit annoyed because the woman didn’t tell him her plan for the winterholiday.C. The man is sorry about not being able to go to Malaysia.D. The woman is excited about spending the winter holiday in Malaysia without the man.Section BDirections: In Section B, you will hear two short passages and one longer conversation, and you will be asked several questions on each of the passages and the conversation. The passages and the conversation will be read twice, but the questions will be spoken only once. When you hear aquestion, read the four possible answers on your paper and decide which one would be the best answer to the question you have heard.Questions 11 through 13 are based on the following passage.11. A. 70. B. 80. C. 130. D. 15.12. A. On Tuesdays. B. On Wednesdays.C. On Sundays.D. On Mondays.13. A. The English Family club. B. The painting club.C. The sports club.D. The music club.Questions 14 through 16 are based on the following passage.14. A. Because they haven’t as much interest in finding the cure as in space travel.B. Because there are too many kinds of cold viruses for them to identify.C. Because it is not economical to find a cure for each type of cold.D. Because they believe people can recover without treatment.15. A. They reveal the seriousness of the problem.B. They indicate how fast the virus spreads.C. They tell us what kind of medicine to take.D. They show our body is fighting the virus.16. A. It can actually does more harm than good.B. It causes damage to some organs of our body.C. It works better when combined with other remedies.D. It helps us to recover much sooner.Questions 17 through 20 are based on the following conversation.17. A. It lasts till today. B. It lasted about ten years.C. It’ s not mentioned in the conversation.D. It lasts forever.18. A. The commercial success of several boys and girls.B. The funny daily stories that happened to a group of close friends.C. How people in Manhattan made their living.D. American culture, mainly the coffee culture.19. A. It always received positive reviews from the critics.B. It enjoyed a high rate of watching.C. It was used as a tool for English learning all over the world.D. It became a cultural phenomenon.20. A. They may go to the “ Central Perk ” for a cup of coffee .B. They may open a new coffee shop together.C. They may start practicing English with each other.D. They may go to the woman ’ s place to enjoy the show.II. Grammar and VocabularySection ADirections: After reading the passage below, fill in the blanks to make the passage coherent and grammatically correct. For the blanks with a given word, fill in each blank with the proper formof the given word; for the other blanks, use one word that best fits each blank.I was eighteen, summer fading, when my parents drove me to my university apartment. It was my first apartment. ___21___ (walk) my parents solemnly back to their car, I noticed that my mother had tears in her eyes. I ___22___ (struggle) to hold back my own. Such a strong woman was she ___23___ it was rare to see such a show of emotion. At the time, I was rather surprised. Being the youngest of five children, I thought that my parents were accustomed to ___24___ (let) go. But maybe it ’ s something that never gets any easier, ___ 25___ _______ _______ many practice swings you get. As my parents drove off, I realized that they would return to an empty home, ___26___ all of their children leaving to pursue dreams and lives of their own. Their nest, full of love and joy for so long, was now empty. Relishing (憧憬) my new-found freedom, I concentrated on my college life. My parents did their best to give me space to learn and grow, even if I neglected to call or visit. It was a time of “ firsts, ” and a taste of first “ lasts. ”I have recently been playing Travel Frog, a mobile game that has me emotionally ___27___ (influence). In the game you gather resources, send your frog on his adventures and your payoff is, *drum roll please* ... postcards. That ’ s right, postcards. I thought it was a silly, overly-simplistic game at first, but then it started to bring back memories from long ago. While the game lacks the narrative detail or the interactivity of other games, you have a lesson ___28___ (learn) from your itinerant (四处奔波的) “Frog Son”.You do not control when he sets off on his adventures, ___ 29___ can you be sure that your hard work will land you a coveted (梦寐以求的) postcard. This game, however, has emotionally affected many players. They ___30___ (remind) of their parents who restlessly await their return home, their familiar voices, their love. Parents sacrifice a large part of themselves for their children. It is a sacrifice that can only be paid back with love.Section BDirections: Complete the passage with the words given in the table. Each word can be used onlyCan Indoor Plants Really Purify the Air?Plants are very important to human life. Through photosynthesis ( 光合作用), they transform carbon dioxide into fresh oxygen. They are said to ___31___ toxins from the air we breathe —but is this true?One famous NASA experiment, published in 1989, found that indoor plants can clean the air by removing cancer-causing pollutants like formaldehyde and benzene. Later research has found that soil micro-organisms in potted plants also play a part in cleaning indoor air.Based on this research, some scientists say house plants are ___32___ air purifiers, and the bigger and leafier the plant, the better. “ The amount of leaf surface area can ___33___ the rate of air purification, ” says Bill Wolverton, a former NASA research scientist who conducted that 1989 plant study.Other experts, however, say the ___34___ that plants can effectively accomplish this feat is far from conclusive.“There are no definitive studies to show that having indoor plants can ___35___ increase theair quality in your home, ” says Luz Claudio, a professor of environmental medicine and public health at the Icahn School of Medicine at Mount Sinai. There ’no s question that plants are capable of removing volatile chemical toxins from the air “ under laboratory conditions, ” according to Claudio. But in the real world — in your home or in your office space — the notion that putting a few plants together can ___36___ your air doesn’t have much hard science to back it up.Most research efforts to date, including the NASA study, placed indoor plants in small, sealed environments in order to ___37___ how much air-purifying power they have. But those studies aren ’really t ___38___ to what happens in a house, says Stanley Kays, a professor of horticulture at the University of Georgia.In many cases, the air in your home ___39___ turns over — that is, exchanges places with outdoor air —once every hour. “ In most instances, air exchange with the outside has a far greater effect on indoor air quality than plants, ” Kays says.Many people may be disappointed by what Kays said, but the professor also made it clear that he believes house plants are ___40___ — they are not only pleasant living companions, but also provide a number of health benefits. Studies have shown plants can knock out stress by calming the sympathetic nervous system, and can also make people feel happier. More research shows spending time around nature has a positive effect on a person ’ s mood and energy levels.III. Reading comprehensionSection ADirections: For each blank in the following passages there are four words or phrases marked A, B, C and D. Fill in each blank with the word or phrase that best fits the context.What the scientists are saying…The first primate (灵长目动物) clonesFor the first time, scientists have used the technique that produced Dolly the sheep to clone monkeys. The Chinese researchers who produced the two macaques say that having access to genetically identical primates will be a huge ___41___ to medical research. It will give scientists a clearer understanding of genetic ___42___ by enabling them to compare animals who are identical except for one tweaked gene; when ___43___ drugs, it will make it possible to rule out the possibility that variations in outcomes are down to genetic ___44___. But other experts have raised a host of ___45___. The somatic cell nuclear transfer (SCNT) technique involves ___46___ a cell nucleus to a donated nucleus-free egg that is then prompted to develop into an embryo(胚胎). Although 23 species have been cloned in this way, primates have only been cloned before using a less complex embryo-splitting technique. Similar to the process that creates twins, it can only lead to a very ___47___ number of genetically identical individuals. SCNT can in ___48___ lead to a far larger number of clones, but in the Chinese experiment, the fail rate was very high. The team implanted scores of embryos, but only two monkeys survived beyond a few days. ___49___ to that is the concern that by cloning a primate species, the team has broken down a significant ___50___ on the way to cloning humans.Herbal remedy dangerHerbal remedies such as St. John and ginseng may be ___51___ when used alongside conventional drugs, reports The Guardian. In a review of medical literature, researchers atStellenbosch University in South Africa found several ___52___ of alternative treatments appearing to ___53___ with prescription drugs, resulting in potentially dangerous side effects. In one case, the autopsy (解剖) of a 55-year-old who died while swimming concluded that the ginkgo biloba supplements he had been taking may have ___54___ his anti-seizure ( 防止发作) medicine. Other cases documented patients on statins appearing to suffer complications linked to flaxseed, St. John’s wort and green tea. “ If you are taking herbal remedies, you should ___55___it to your clinician, id one of ” sa the report ’ s authors, Dr Charles Awortwe.41. A. threat B. damage C. benefit D. potential42. A. variations B. diseases C. structures D. factors43. A. manufacturing B. applying C. testing D. prescribing44. A. mess B. differences C. losses D. recombination45. A. concerns B. focuses C. funds D. suspicion46. A. translating B. transferring C. connecting D. reversing47. A. magnificent B. astonishing C. limited D. accurate48. A. theory B. reality C. advance D. addition49. A. Attached B. Related C. Compared D. Added50. A. access B. key C. barrier D. contribution51. A. harmful B. useful C. helpful D. purposeful52. A. methods B. figures C. problems D. instances53. A. deal B. interact C. mix D. identify54. A. put forward B. moved up C. held down D. carried on55. A. claim B. avoid C. classify D. mentionSection BDirections: Read the following three passages. Each passage is followed by several questions or unfinished statements. For each of them there are four choices marked A, B, C and D. Choose the one that fits best according to the information given in the passage you have just read.(A)Cure for tiredness?Staying up late is a potential battle between parents and kids. But the solution could be as simple as changing your meal time.Researchers at the University of Surry, UK, found that delaying meals could help change one of the internal body clocks. Besides a “ master ” cloc k in the brain, there are clocks in other parts of the body. They are usually synchronized according to factors including light.During the study, researchers tested 10 participants to examine the effect of changing meal times on their body clocks. The participants were given three meals – breakfast, lunch and dinner. In the first stage, participants received breakfast 30 minutes after waking. Lunch and dinner followed, after 5-hour intervals. In the second stage, each meal was delayed by 5 hours. Right after each stage, blood and fat samples were collected.Results showed that later meal times greatly influenced blood sugar levels. A 5-hour delay in meal times caused a 5-hour delay in the internal blood sugar rhythms.The discovery showed that meal times are in line with the body clock that controls bloodsugar levels.This is a small study but the researchers believe the findings could help jet lag sufferers and night-shift workers.In a study by the University of Surrey in 2013, researchers explored what happened when a person ’ s body was changed from a normal pattern to that of a night-shift worker’s.After people work through the night, over 97 percent of the body ’rhythmic s genes are disrupted.These findings explain why we feel so bad following a long flight, or after working at night, according to Simon Archer, one of the study ’ s researchers.“It ’s like living in a house. There ’s a clock in every room in the house and in all of those rooms those clocks are now disrupted, which of course lea ds to chaos in the household, ” f ellow researcher DerkJan Dijk told the BBC.Changing meal times didn’t affect the “ master ” body clock –the one controlling when we get sleepy – but it can reset the body clock that controls blood sugar levels.This woul dn’t necessarily cure jet lag completely, but it might reduce the negative effects.A study published earlier this year suggested that just a weekend camping trip could be enough to reset our body clocks. And now this latest research shows regular food schedules could play a key part too.56. What did researchers at the University of Surrey find from their new study?A. Connections between the “ master ” clock and clocks in other parts of the body.B. Changing meal times can be enough to reset one of our body clocks.C. A delay in meal times causes an irregular change in blood sugar rhythms.D. Blood sugar levels are affected by when we eat rather than by our internal clocks.57. Which of the following statements is TRUE about the new study, according to the article?A. The interval between each meal being given was different.B. Blood and fat samples of the two groups of participants were collected.C. Participants were asked to report their feelings after each stage.D. Each meal was served five hours later during the second stage.58. What can we learn from the study by researchers at the University of Surrey from 2013?A. All our body ’ s genes would be disrupted if we worked through the night.B. Our genes often become less active after a long flight or night of work.C. The disruption of one gene could lead to the disruption of other genes.D. A disruption to the body ’ s rhythmic genes can cause people to feel bad.59. According to the article, ______.A. it ’ s impossible to reduce the n egative effects caused by jet lag or night workB. there is more than one way to reset body clocksC. the “ master ” body clock controls all the other body clocksD. a change in meal times can reset the “master”body clock(B)Canada Apprentice (学徒) Loan BasicsThe Canada Apprentice Loan is available to help registered Red Sealapprentices cover the cost of their training.What you need to know●The Government of Canada offers apprentices registered in a Red Seal Trade apprenticeship program up to $4,000 per period of technical training.●You can get Canada Apprentice Loans for up to 5 periods of technical training.●Your loan will be interest-free for up to 6 years as long as you are confirmed as being registered in a Red Seal Trade apprenticeship program.●You do not have to make any loan payments as long as your loan is in interest-free status. Eligibility (资格)To be eligible, you must meet all of these criteria :●be a Canadian Citizen, Permanent Resident, or Protected Person;●be registered in a Red Seal Trade apprenticeship program that is designated by the province or territory where you are registered as an apprentice ;●be enrolled in block release technical training or the equivalent fulltime technical training with an approved technical training provider;●pass a credit check (required if you are applying for the first time) .You are not eligible if you:●are a high school student;●are an apprentice registered in the province of Quebec ;●are receiving a Canada Student Loan for the same technical training ;●have been told that you are restricted from receiving a Canada Apprentice Loan or a Canada Student Loan;●have already received funding for 5 periods of technical training ;●have already received 6 years of interest-free status.60. Who will fail to get Canada Apprentice Loans according to the passage?A. An apprentice who used to study in the province of Quebec.B. An apprentice who got the Canadian Citizenship three years ago.C. An apprentice who is looking for an approved technical training provider.D. An apprentice who has been funded for technical training three times.61. Which of the following statements is False according to the passage?A. You can get the loan without paying the interest.B. You can totally get the loan of $20,000 in 5 periods.C. You should be registered in a Red Seal Trade apprenticeship program.D. You have to make some loan payment even though your loan is in interest-free status. 高62. The purpose of the passage is intended to ________.A. promote the business of Canadian banksB. help students in need complete their studiesC. recruit more apprentices for Canadian companiesD. provide apprentices with fund to receive technical training(C)The b attle for women right to vote’sOne hundred years ago, British women were given the vote for the first time. How did it comeabout?The first appeals for women ’ s right to vote in Britain date from the early 19th century. In 1818, in his Plan of Parliamentary Reform, Jeremy Bentham insisted that women should be given the vote. Women at the time had no political rights at all – they were deemed to be represented by their husbands or fathers. The old arguments prevailed. Women, it was said, were mentally less able than men; their “ natural sphere ” was in the home; they were unable to fight for their country, and thus undeserving of full rights; moreover, they simply didn’t want the vote. This was at least partly true. “ I have never felt the want of a vote, ” declared Florence Nightingale in 1867, while Queen Victoria condemned the “ mad, wicked folly of women ’ s rights ” . Even George Eliot was reluctant to back the cause.It wasn’t until the second half of the 19th century that the first campaigning women’s groups were formed. Initially they focused on the lack of education, employment opportunities and legal rights for women (married women, at the time, had no independent legal standing); but the question of the vote gradually became central to their demands –both symbolically, as a recogni tion of women ’ s rights, and practically, as a means of improving women’s lives.However, the women’ s campaigning was still a subject of debate. While most historians agree that the campaigns were initially very effective in mobilizing women and highlighting injustices, a series of mass processions followed; more than 250,000 women protested in Hyde Park in 1908. Many were arrested and ill-treated; prisoners who went on hunger strike were brutally force-fed. Over time they became steadily more militant –smashing shop windows, setting fire to letter boxes, libraries and even homes. The PM, Herbert Asquith, an opponent of women’ s votes, was attacked with a dog whip. Such use of violence was thought, certainly at the time, to have been unfavorable.With the sacrifices of the First World War strengthening support for widening the right to vote generally, women suspended campaigning. More than a million women were newly employed outside the home --in munitions (军需品) factories, engineering works. Crucially, Asquith was replaced as PM by David Lloyd George, a supporter of votes for women. The Representation of the People Act 1918 was introduced by the coalition government and passed by a majority of 385 to 55, gaining the Royal Assent on 6 February 1918. Women over 30, who were householders or married to one, or university graduates, were given the vote.63. Which of the following is NOT the reason why women were not qualified to vote?A. Women were supposed to do housework and serve their husbands.B. Women were too weak to fight against enemies.C. Women had already enjoyed many political rights.D. Women were not as intelligent as men.64. According to the passage, why did women ’s campaigning arouse debat e?A. Because it failed to mobilize women and emphasize injustices.B. Because women were put in prison and abused during the protest.C. Because most women didn ’t want the vote.D. Because all the emotional behaviors were regarded as improper.65. T he word “militant ” (in Line 5, Para.4) probably refers to ______________.A. imposing.B. extreme.C. negative.D. obedient.66. What can be inferred from the passage?A. Women stopped protesting for their vote because they were offered more job opportunities.B. The PM, Herbert Asquith, an opponent of women committed suicide. ’ s votes,C. The first campaigning women groups were formed originally for the sake of legal rights.D. All women can enjoy their right to vote since the introduction of People Act.Section CDirections: Read the following passage. Fill in each blank with a proper sentence given in the box. Each sentence can be used only once. Note that there are two more sentences than you needNo one enjoys the moment. You are stuck at the back of a queue and as those in other lines move ahead and get served, the time to decide arrives. ____67____This question has now been solved by researchers at Harvard Business School. According to what they have found in a new study, they suggest people think twice before switching queues.The research was led by Ryan Buell, an expert in service management. He looked into consumer queuing behavior after working with economists on what is known as “ last-place aversion, the ” discomfort people feel when they kn ow they earn less than others or consider themselves at the bottom of the social pile for some other reason. As a result of this aversion to being the last, when a person finds himself at the end of a queue, he can make decisions that he will later regret.Buell began by observing people at a multi-checkout grocery store and then set up an online survey. People who took part in the survey were told it would take about five minutes. In reality, it took only one minute, but when participants logged in for the survey, they were forced to wait in a virtual queue displayed on the screen. They started at the back and could wait, switch to a second queue or choose to leave.____68____ On average, however, those who switched waited 10 percent longer than if they had stayed put. Those who switched twice ended up waiting 67 percent longer than if they had never moved.“When we join a queue, we tend to make the most rational choice we can, which means joining the shortest queue. ____69 ____ Unfortunately, we can of ten get it wrong, ” said Buell.____70____ After that, the aversion fades. The researcher suggests people have a chat with the person in front so that they can pass the time more comfortably until someone else joinsbehind them. “ Remember that the pers on in front of you was the last until you arrived, so someone will show up if you hang around long enou gh, ” Buell saidIV. Summary WritingDirections: Read the following passage. Summarize the main idea and the main point(s) of the passage in no more than 60 words. Use your own words as far as possible.As technology grows, many university instructors are finding ways to guide online learning platforms into their classrooms. Programs such as Blackboard, WebCT and Moodle allow teachers to post reading assignments, PowerPoint presentations, lecture notes and quizzes for students to complete outside of class. While posting lessons online can be friendly to students' communication styles and easily accessible, they also cause disadvantages.One disadvantage is that it may encourage students to depend on technology in the classroom. Instead of physical textbooks, many now bring cellphones to access materials during class discussions. While electronic devices can be valuable learning tools, they also can lead to distractions from learning, such as social networking and online games. It is extremely difficult for students being exposed to multiple electronic tasks to focus or remember key information.A second disadvantage is that online lessons open up potential for cheating. Many instructors require students to complete quizzes, post within discussion groups or submit major assignments online. As a result, there are some students having someone else complete their assignments. A contributing factor is that online assignments are best suitable for those self-motivated, self-directed students. Students who struggle with organization and completing assignments may find it easy to cheat online.In spite of these disadvantages, educators can take steps to make sure students use online lessons responsibly. If instructors are uncomfortable with electronic devices in the classroom, they can require students to print out assignments and readings to reference during sessions. To prevent cheating, teachers can use online assignments as a supplement to traditional in-class work, or create open-ended assignments rather than using assignments like multiple-choice quizzes that have only one right answer. Being familiar with what the platform looks like from a student perspective also can help instructors avoid potential pitfalls.V. TranslationDirections: Translate the following sentences into English, using the words given in the brackets.72. 多参加志愿者活动,它能使你成为更好的人。

2018年 高中高中高考英语全国卷 2 阅读理解 完形填空 文章翻译(共30张PPT)

2018年 高中高中高考英语全国卷 2 阅读理解 完形填空 文章翻译(共30张PPT)
形填空 文章翻译
第七页,共三十页。
Member of
staff 职员
Miss Drake
Miss Drake
Cost
花费
£150
£150
21. Which activity will you choose if you want
to go camping?
A. OUT. B. WBP.
C. CRF. D.
垫子和装饰品…学习技巧并且 离开时带走摩
登的不寻常的纺织品。
2018年 高中高中高考英语(yīnɡ yǔ)全国卷 2 阅读理解 完
形填空 文章翻译
第六页,共三十页。
Activity 活动
Description 描述
Potty about Potter(POT)
Potty about Potter(POT)
Of the common berries, strawberries are highest in vitamin C, although, because of their seeds, raspberries contain a little more protein(蛋白质), iron and zinc (not that fruits have much protein). Blueberries are particularly high in antioxidants(抗 氧化物质(wùzhì)). The yellow and orange stone fruits such as peaches are high in the carotenoids we turn into vitamin A
大战战场 们在第2天前往法国北部访问一战战场。第3

USACO2018年2月银级题2

USACO2018年2月银级题2

USACO 2018 F EBRUARY C ONTEST , S ILVER P ROBLEM 2. S NOW B OOTSIt's winter on the farm, and that means snow! There are tiles on the path from the farmhouse to the barn, conveniently numbered , and tile is covered in feet of snow.Farmer John starts o ff on tile and must reach tile to wake up the cows. Tile is sheltered by the farmhouse roof, and tile is sheltered by the barn roof, so neither of these tiles has any snow. But to step on the other tiles, Farmer John needs to wear boots!In his foul-weather backpack, Farmer John has pairs of boots, numbered . Some pairs are more heavy-duty than others,and some pairs are more agile than others. In particular, pair lets FJ step in snow at most feet deep, and lets FJ move at most forward in each step.Unfortunately, the boots are packed in such a way that Farmer John can only access the topmost pair at any given time. So at any time, Farmer John can either put on the topmost pair of boots (discarding his old pair) or discard the topmost pair of boots (making a new pair of boots accessible).Farmer John can only change boots while standing on a tile. If that tile has feet of snow, both the boots he takes o ff AND the boots he puts on must be able to withstand at least feet of snow. Intermediate pairs of boots which he discards without wearing do not need to satisfy this restriction.Help Farmer John minimize waste, by determining the minimum number of pairs of boots he needs to discard in order to reach the barn. You may assume that Farmer John is initially not wearing any boots.INPUT FORMAT (file snowboots.in):The first line contains two space-separated integers and ().The second line contains space-separated integers. The th integer is , giving the depth of snow on tile (). It's guaranteed that .The next lines contain two space-separated integers each. The first integer on line is , the maximum depth of snow in which pair can step. The second integer on line is , the maximum step size for pair . It's guaranteed that and .The boots are described in top-to-bottom order, so pair is the topmost pair in FJ's backpack, and so forth.OUTPUT FORMAT (file snowboots.out):The output should consist of a single integer, giving the minimum number of boots Farmer John needs to discard. It's guaranteed that it will be possible for FJ to make it to the barn.SAMPLE INPUT:10 40 2 8 3 6 7 5 1 4 02 34 23 4N 1…N i f i 1N 1N B 1…B i s i d i f f N B 2≤N ,B ≤250N i f i i 0≤≤f i 109==0f 1f N B i +2s i i i +2d i i 0≤≤s i 1091≤≤N −1d i 1Problem credits: Brian Dean and Dhruv Rohatgi 。

2018考研英语二真题及答案

2018考研英语二真题及答案

2018考研英语二真题及答案SectionⅠ Use of EnglishDirections:Read the following text. Choose the best word(s) for each numbered blank and mark[A],[B], [C] or [D] on the ANSWER SHEET. (10 points)Why do people read negative Internet comments and do other things that will obviously bepainful? Because humans have an inherent need to 1 uncertainty, according to a recent study inPsychological Science. The new research reveals that the need to know is strong that people will 2 tosatisfy their curiosity even when it is clear the answer will 3 .In a series of experiments, behavioral scientists at the University of Chicago and the Wisconsinschool of Business tested students’ willingness to 4 themselves to unpleasant stimuli in an effort tosatisfy curiosity. For one 5 , each participant was shown a pile of pens that the researcher claimedwere from a previous experiment. The twist? Half of the pens would 6 anelectric shock whenclicked.Twenty-seven students were told with pens were electrified; another twenty-seven were toldonly that some were electrified. 7 left alone in the room. The students who did not know which oneswould shock them clicked more pens and incurred more shocks than the students who knew thatwould 8 . Subsequent experiments reproduced this effect with other stimuli, 9 the sound offingernails on a chalkboard and photographs of disgusting insects.The drive to 10 is deeply rooted in humans, much the same as the basic drives for 11 or shelter,says Christopher Hsee of the University of Chicago. Curiosity is often considered a good instinct—itcan 12 new scientific advances, for instance—but sometimes such 13 can backfire. The insight thatcuriosity can drive you to do 14 things is a profound one.Unhealthy curiosity is possible to 15 , however. In a final experiment, participants who wereencouraged to 16 how they would feel after viewing an unpleasant picture were less likely to 17 tosee such an image. These results suggest that imagining the 18 of following through on one’scuriosity ahead of time can help determine 19 it is worth the endeavor. Thinking about long-term 20is key to reducing the possible negative effects of curiosity,”Hsee says. In other words, don’t readonline comments.1. A.ignore B.protect C.discuss D.resolve答案:D. resolve考点:词义辨析解析:文章首段第一句话就交代了全文主旨:Why do people read negative Internetcomments and do other things that will obviously be painful? 人们浏览网络负面评论信息以及做一些明显令人痛苦的事情的原因。

2018 高考英语全国卷 2 阅读理解 完形填空 文章翻译

2018 高考英语全国卷 2 阅读理解 完形填空 文章翻译
staff 职员
Outdoor Take yourself out of your comfort zone for a Mr.
Adventure week, discover new personal qualities, and learn Clemens
(OUT)
new skills. You will be able to take part in a
number of activities from canoeing to wild
camping on Dartmoor. Learn rock climbing and
work as a team, and enjoy the great outdoor
environment.
户外冒险 让自己走出你的舒适空间,发现新的个人品 Mr.
staff 职员 花费
CraftyFoxes( Four days of product design centred around Mrs. Goode £30
CRF)
textiles. Making lovely objects using recycled
and made materials. Bags, cushions and
Oxford to see the film locations, picnic lunch
outside Oxford’s Christchurch, boating on the River Cherwell through the University Parks,
before heading back to Exeter. Potty about 参观华纳兄弟工作室,(旅程的内容包含) Potter(POT) 商店站买野餐用品,在泰晤士河畔斯特雷特

2018USACO真题Gold2

2018USACO真题Gold2

USACO 2017 D ECEMBER C ONTEST , G OLDP ROBLEM 2. B ARN P AINTINGFarmer John has a large farm with barns (), some of which are already painted and some not yet painted. Farmer John wants to paint these remaining barns so that all the barns are painted, but he only has three paint colors available.Moreover, his prize cow Bessie becomes confused if two barns that are directly reachable from one another are the same color,so he wants to make sure this situation does not happen.It is guaranteed that the connections between the barns do not form any 'cycles'. That is, between any two barns, there is at most one sequence of connections that will lead from one to the other.How many ways can Farmer John paint the remaining yet-uncolored barns?INPUT FORMAT (file barnpainting.in):The first line contains two integers and (), respectively the number of barns on the farm and the number of barns that have already been painted.The next lines each contain two integers and () describing a path directly connecting barns and .The next lines each contain two integers and (, ) indicating that barn is painted with color .OUTPUT FORMAT (file barnpainting.out):Compute the number of valid ways to paint the remaining barns, modulo , such that no two barns which are directly connected are the same color.SAMPLE INPUT:4 11 21 31 44 3SAMPLE OUTPUT:8 Problem credits: Nick Wu N 1≤N ≤105N N K 0≤K ≤N N −1x y 1≤x ,y ≤N ,x ≠y x y K b c 1≤b ≤N 1≤c ≤3b c +7109。

2018USACO真题Bronze2

2018USACO真题Bronze2

USACO 2017 D ECEMBER C ONTEST , B RONZEP ROBLEM 2. T HE B OVINE S HUFFLEConvinced that happy cows generate more milk, Farmer John has installed a giant disco ball in his barn and plans to teach his cows to dance!Looking up popular cow dances, Farmer John decides to teach his cows the "Bovine Shu ffle". The Bovine Shu ffle consists of his cows () lining up in a row in some order, then performing three "shu ffles" in a row, after which they will be lined up in some possibly di fferent order. To make it easier for his cows to locate themselves, Farmer John marks the locations for his line of cows with positions , so the first cow in the lineup will be in position 1, the next in position 2, and so on, up toposition .A shu ffle is described with N numbers, , where the cow in position moves to position during the shu ffle (and so,each is in the range ). Every cow moves to its new location during the shu ffle. Fortunately, all the 's are distinct, so no two cows try to move to the same position during a shu ffle.Farmer John's cows are each assigned distinct 7-digit integer ID numbers. If you are given the ordering of the cows after three shu ffles, please determine their initial order.INPUT FORMAT (file shu ffle.in):The first line of input contains , the number of cows. The next line contains the integers . The final line contains the order of the cows after three shu ffles, with each cow specified by its ID number.OUTPUT FORMAT (file shu ffle.out):You should write lines of output, with a single cow ID per line, specifying the order of the cows before the three shu ffles.SAMPLE INPUT:51 3 4 5 21234567 2222222 3333333 4444444 5555555SAMPLE OUTPUT:12345675555555222222233333334444444Problem credits: Brian Dean N 1≤N ≤1001…N N …a 1a N i a i a i 1…N a i N N …a 1a N N N 。

2018USACO铜级第二题(翻译)

2018USACO铜级第二题(翻译)

USACO 2017年首轮月赛铜级题2Bovine Shuffle农夫John确信快乐的奶牛能产出更多的牛奶,所以他在他的谷仓里装了一个巨大的迪斯科球,并打算教他的奶牛跳舞!农夫John在看了很多流行的奶牛舞后,决定教他的奶牛跳“Bovine Shuffle"。

“Bovine Shuffle"需要他的N只牛(1 ≤ N ≤ 100)按顺序排成一排,依次进行“Shuffle(洗牌)”这个动作,也就是轮换位置排成不同的顺序。

为了让奶牛更容易找到自己的位置,John为他的牛按1 … N的顺序排上了号,也就是说第一个奶牛是位置1,第二个是位置2,一直到最后一只是位置N。

每场Shuffle都是用N个数字从a1…a N来标明,换句话说,在这个过程中,原本位置在i的奶牛换到了位置a i (每一次的移动位置a i都在1…N的范围内).每头牛在Shuffle的过程中都会移动到它的新位置。

幸运的是,所有这些移动位置a i都是清楚的,不会有两头奶牛跑去同一个位置上。

农场主John给每头奶牛都标上了7位整数位的ID号。

如果给你了3次洗牌后的奶牛编号顺序,请给出原本的奶牛顺序。

输入格式(file shuffle.in):第一行输入N代表了奶牛的总数。

下一行输入在a1至a n间的整数之间的整数N。

最后一样写三次洗牌后,N头奶牛的ID编号顺序。

输出格式(file shuffle.out):你应该每一行写一头奶牛的ID号,写N行来标明3次洗牌后的奶牛顺序。

样例输入:51 3 4 5 21234567 2222222 3333333 4444444 5555555样品输出:12345675555555222222233333334444444。

2018USACO金级第一题(翻译)

2018USACO金级第一题(翻译)

USACO 2017年首轮月赛金级题1一物换一物贝茜和埃尔西各烤了N(1≤N≤105)块馅饼。

在这2N块馅饼中,每一块在贝西和埃尔西看来都有一个美味值,然而他们俩对于美味的感受有所不同,所以同一块馅饼的美味值评分不尽相同。

贝茜正在考虑送一个馅饼给埃尔茜。

如果埃尔西收到贝西的馅饼,她觉得应该礼尚往来,也要给贝茜一块自己烤的馅饼。

因此,为了不显得小气和张扬,埃尔西会尽量挑选一个在她看来美味值和贝茜给她的馅饼差不多但不会超过D(1≤D≤109)单位美味值的馅饼作为回礼。

这样的派可能不存在,如果是这样的话埃尔西会感到无地自容。

但是如果埃尔西给贝西一个馅饼作为回报,贝茜同样也会试着挑选一个在她看来美味值和埃尔西给她的馅饼差不多但不会超过D(1≤D≤109)单位美味值的馅饼作为回礼。

如果不存在这样的派,贝茜也会感到无地自容。

因此贝茜会再次把她的馅饼送给埃尔西。

这一循环将持续下去,直到其中一位羞愧之至而再无礼物可以交换,或其中一个奶牛会得到一个她认为美味值为0的馅饼,在这种情况下,礼物交换将会在欢快的气氛下结束。

注意,一个馅饼既不能送两次,也不能把对方送过来的返还给她。

贝西都可以选择N块馅饼中的任意一块作为她最初的礼物给埃尔西,计算出在双方都对对方礼物满意时,已经交换礼物的最小次数。

输入格式(文件piepie.in):第一行包含两个整数N和D。

接下来的2N行包含两个不同的整数,分别表示某个特定的饼在贝茜眼中的美味值和在埃尔西眼中的美味值。

前N行代表是贝西的馅饼,后N行代表埃尔西的馅饼。

所有美味值的区间都在[0,109]。

输出格式(文件piepie.out):输出文件应该有N行。

第i行为一个整数:交换礼物从贝茜的第i个馅饼开始直到双方都满意时所交换礼物的最小次数。

如果从第i个馅饼开始的礼物交换一直达不到双方均满意的结果,则第i行就用“-1”替代。

SAMPLEINPUT:2 11 15 04 21 4SAMPLE OUTPUT:31。

USACO 2018.12月铂金组Platinum竞赛真题(中文)

USACO 2018.12月铂金组Platinum竞赛真题(中文)

USACO2018D ECEMBER C ONTEST,P LATINUMP ROBLEM1.B ALANCE B EAMBessie为了存钱给她的牛棚新建一间隔间,开始在当地的马戏团里表演,通过在平衡木上小心地来回走动来展示她卓越的平衡能力。

Bessie能够通过表演赚到的钱取决于她最终成功跳下平衡木的位置。

平衡木上从左向右的位置记为$0,1,\ldots,N+1$。

如果Bessie到达了位置$0$或是$N+1$,她就会从平衡木的一端掉下去,遗憾地得不到报酬。

如果Bessie处在一个给定的位置$k$,她可以进行下面两项中的任意一项:1.投掷一枚硬币。

如果背面朝上,她前往位置$k-1$,如果正面朝上,她前往位置$k+1$(也就是说,每种可能性$\frac{1}{2}$的概率)。

2.跳下平衡木,获得$f(k)$的报酬($1\leq f(k)\leq10^9$)。

Bessie意识到她并不能保证结果能够得到某一特定数量的报酬,这是由于她的移动是由随机的掷硬币结果控制。

然而,基于她的起始位置,她想要求出当她进行一系列最优的决定之后,她能够得到的期望报酬(“最优”指的是这些决定能够带来最高可能的期望报酬)。

例如,如果她的策略能够使她以$1/2$的概率获得$10$的报酬,$1/4$的概率获得$8$的报酬,$1/4$的概率获得$0$的报酬,那么她的期望报酬为加权平均值$10(1/2)+8(1/4)+0(1/4)= 7$.输入格式(文件名:balance.in):输入的第一行包含$N$($2\leq N\leq10^5$)。

以下$N$行包含$f(1)\ldots f(N)$.输出格式(文件名:balance.out):输出$N$行。

第$i$行输出$10^5$乘以Bessie从位置$i$开始使用最优策略能够获得的报酬的期望值,向下取整。

输入样例:213输出样例:150000300000供题:Franklyn Wang and Spencer ComptonUSACO2018D ECEMBER C ONTEST,P LATINUMP ROBLEM2.S ORT I T O UTFJ有$N$($1\leq N\leq10^5$)头奶牛(分别用$1\ldots N$编号)排成一行。

2018英语二真题与答案

2018英语二真题与答案

Section I Use of EnglishDirections:Read the following text. Choose the best word (s) for each numbered blank and mark A, B, C or D on the ANSWER SHEET.(10 points)Why do people read negative Internet comments and do other things that will obviously be painful? Because humans have an inherent need to 1 uncertainty, according to a recent study in Psychological Science. The new research reveals that the need to know is so strong that people will 2 to satisfy their curiosity even when it is clear the answer will 3 .In a series of four experiments, behavioral scientists at the University of Chicago and the Wisconsin School of Business tested. Student’s willingness to 4 themselves to unpleasant stimuli in an effort to satisfy curiosity. For one 5 each participant was shown a pile of pens that the researcher claimed were from a previous experiment. The twist? Half of the pens would 6 an electric shock when clicked.Twenty-seven students were told which pens were electrified, another twenty-seven were told only that some were electrified 7 left alone in the room, the students who did not know which ones would shock them clicked more pens and incurred more shocks than the students who knew what would 8 subsequent experiments reproduced, this effect with otherstimuli 9 the sound of finger nails on a chalkboard and photographs of disgusting insects.The drive to_10_is deeply rooted in humans. Much the same as the basic drives for_11_or shelter, says Christopher Hsee of the University of Chicago Curiosity is often considered a good instinct-it can _12_New Scientific advances, for instance-but sometimes such_13_can backfire, the insight that curiosity can drive you to do _14_things is a profound one.Unhealthy curiosity is possible to 15 , however, in a final experiment, participants who were encouraged to 16 how they would feel after viewing an unpleasant picture were less likelyto 17 to see such an image. These results suggest that imagining the 18 of following through on one’s curiosity ahead of time can help determine 19 it is worth the endeavor. ”Thinking about long-term 20 is key to reducing the possible negative effects of curiosity. Hsee says “in other words, don’t read online comments”.1. [A]Protect [B] resolve [C] discuss [D] ignore2. [A]refuse [B] wait [C] regret [D] seek3. [A]hurt [B] last [C]mislead [D] rise4. [A]alert [B] tie [C] treat [D] expose5. [A]message [B] review [C] trial [D] concept6.[A] remove [B] weaken [C] interrupt [D] deliver7.[A]when [B] if [C] though [D] unless8.[A] continue [B] happen [C] disappear [D] change9.[A] rather than [B] regardless of [C] such as [D] owing to 10.[A] discover [B] forgive [C] forget [D] disagree11.[A] pay [B] marriage [C] schooling [D] food12.[A] lead to [B]rest on [C] learn from [D] begin with13.[A] withdrawal [B] persistence [C] inquiry [D] diligence14.[A] self-reliant [B] self-destructive [C] self-evident [D] self-deceptive15.[A] define [B] resist [C]replace [D] trace16.[A] overlook [B] predict [C] design [D] conceal17.[A] remember [B] promise [C] choose [D] pretend18.[A] relief [B] plan [C] duty [D] outcome19.[A] why [B] whether [C] where [D] how20.[A] consequences [B] investments [C] strategies [D] limitationsSection II Reading ComprehensionPart ADirections:Read the following four texts. Answer the questions below each text by choosing A, B, C or D. Mark your answers on the ANSWER SHEET. (40 points)Text 1It is curious that Stephen Koziatek feels almost as though he has to justify his efforts to give his students a better future.Mr. Koziatek is part of something pioneering. He is a teacher at a New Hampshire high school where learning is not something of books and tests and mechanical memorization, but practical. When did it become accepted wisdom that students should be able to name the 13th president of the United States but be utterly overwhelmed by a broken bike chain?As Koziatek knows, there is learning in just about everything. Nothing is necessarily gained by forcing students to learn geometry at a graffitied desk stuck with generations of discarded chewing gum. They can also learn geometry by assembling a bicycle.But he’s also found a kind of insidious prejudice. Working with your hands is seen as almost a mark of inferiority. Schoolsin the family of vocational education “have that stereotype...that it’s for kids who can’t make it academically,”he says.On one hand, that viewpoint is a logical product of America’s evolution. Manufacturing is not the economic engine that it once was. The job security that the US economy once offered to high school graduates has largely evaporated. More educationis the new principle. We want more for our kids, and rightfully so.But the headlong push into bachelor’s degrees for all –and the subtle devaluing of anything less – misses an important point: That’s not the only thing the American economy need. Yes, a bachelor’s degree opens more doors. But even now, 54 percent of the jobs in the country are middle-skill jobs, such as construction and high-skill manufacturing. But only 44 percentof workers are adequately trained.In other words, at a time when the working class has turned the country on its political head, frustrated that the opportunity that once defined America is vanishing, one obvious solution is staring us in the face. There is a gap in working-class jobs, but the workers who need those jobs most aren’t equipped to do them. Koziatek’s Manchester school of Technology High School is trying to fill that gap.Koziatek’s school is a wake-up call. When education becomes one-size-fits-all, it risks overlooking a nation’s diversity of gifts.21. A broken bike chain is mentioned to show students’lack of .[A] practical ability[B] academic training[C] pioneering spirit[D] mechanical memorization22. There exists the prejudice that vocational education is for kids who .[A] have a stereotyped mind[B] have no career motivation[C] are not academically successful[D] are financially disadvantaged23. We can infer from Paragraph 5 that high school graduates .[A] used to have big financial concerns[B] used to have more job opportunities[C] are reluctant to work in manufacturing[D] are entitled to more educational privileges24. The headlong push into bachelor's degrees for all .[A] helps create a lot of middle-skill jobs[B] may narrow the gap in working-class jobs[C] is expected to yield a better-trained workforce[D] indicates the overvaluing of higher education25. The author's attitude toward Koziatek’s school can be described as .[A] supportive[B] tolerant[C] disappointed[D] cautiousText 2While fossil fuels—still generate roughly 85 percent of the world’s energy supply, it’s clearer than ever that the futurebelongs to renewable sources such as wind and solar. The move to renewables is picking up momentum around the world: They now account for more than half of new power sources going on line.Some growth stems from a commitment by governments and farsighted businesses to fund cleaner energy sources. But increasingly the story is about the plummeting prices of renewables, especially wind and solar. The cost of solar panels has dropped by 80 percent and the cost of wind turbines by close to one-third in the past eight years.In many parts of the world renewable energy is already a principal energy source. In Scotland, for example, wind turbines provide enough electricity to power 95 percent of homes. While the rest of the world takes the lead, notably China and Europe, the United States is also seeing a remarkable shift. In March, for the first time, wind and solar power accounted for more than 10 percent of the power generated in the US, reported the US Energy Information Administration.President Trump has underlined fossil fuels—especially coal —as the path to economic growth. In a recent speech in Iowa, he dismissed wind power as an unreliable energy source. But that message did not play well with many in Iowa, where wind turbines dot the fields and provide 36 percent of the state’s electricity generation—and where tech giants like Microsoft are being attracted by the availability of clean energy to power their data centers.The question “What happens when the wind doesn’t blow or the sun doesn’t shine?” has provided a quick put-down for skeptics. But a boost in the storage capacity of batteries is making their ability to keep power flowing around the clock more likely.The advance is driven in part by vehicle manufacturers, who are placing big bets on battery-powered electric vehicles. Although electric cars are still a rarity on roads now, this massive investment could change the picture rapidly in coming years.While there’s a long way to go, the trend lines for renewables are spiking. The pace of change in energy sources appears to be speeding up—perhaps just in time to have a meaningful effect in slowing climate change. What Washington does—or doesn’t do—to promote alternative energy may mean less and less at a time of a global shift in thought.26. The word “plummeting”(Line 3, Para. 2) is closest in meaning to .[A] stabilizing[B] changing[C] falling[D] rising27. According to Paragraph 3, the use of renewable energy in America .[A] is progressing notably[B] is as extensive as in Europe[C] faces many challenges[D] has proved to be impractical28. It can be learned that in Iowa, .[A] wind is a widely used energy source[B] wind energy has replaced fossil fuels[C] tech giants are investing in clean energy[D] there is a shortage of clean energy supply29. Which of the following is true about clean energy according to Paragraphs 5&6?[A] Its application has boosted battery storage.[B] It is commonly used in car manufacturing.[C] Its continuous supply is becoming a reality.[D] Its sustainable exploitation will remain difficult.30. It can be inferred from the last paragraph that renewable energy____.[A] will bring the USA closer to other countries.[B] will accelerate global environmental change.[C] is not really encouraged by the USA government.[D] is not competitive enough with regard to its cost.Text 3The power and ambition of the giants of the digital economy is astonishing-Amazon has just announced the purchase of the upmarket grocery chain Whole Foods for$l3.5bn,but two years ago Facebook paid even more than that to acquire the WhatsApp messaging service, which doesn't have any physical product at all. What WhatsApp offered Facebook was an intricate and finely detailed web of its users' friendships and social lives.Facebook promised the European commission then that it would not link phone numbers to Facebook identities, but it broke the promise almost as soon as the deal went through. Even without knowing what was in the messages, the knowledge of who sent them and to whom was enormously revealing and still could be. What political journalist, what party whip, would not want to know the makeup of the WhatsApp groups in which Therea May's enemies are currently plotting? Itmay be that the value of Whole Foods to Amazon is not so much the 460 shops it owns, but the records of which customers have purchased what.Competition law appears to be the only way to address these imbalances of power. But it is clumsy. For one thing, it is very slow compared to the pace of Change within the digital economy. By the time a problem has been addressed and remedied it may have vanished in the marketplace, to be replaced by new abuses of power. But there is a deeper conceptual problem, too. Competition law as presently interpreted deals with financial disadvantage to consumers and this is not obvious when the users of these services don't pay for them. The users of their Services are not their customers. That would be the people who buy advertising from them-and Facebook and Google, the two virtual giants, dominate digital advertising to the disadvantage of all other media and entertainment companies.The product they're selling is data, and we, the users, convert our lives to date for the benefit of the digital giants. Just as some ants farm the bugs called aphids for the honeydew the produce when they feed, so Google farms us for the data that our digital lives yield. Ants keep predatory insects away from where their aphids feed; Gmail keeps the spamme out of our inboxes. It doesn't feel like a human or democratic relationship, even if both sides benefit.31. According to Paragraph 1, Facebook acquired WhatsApp for its .[A] digital products[B] user information[C] physical assets[D] quality service32. Linking phone numbers to Facebook identities may .[A] worsen political disputes[B] mess up customer records[C] pose a risk to Facebook users[D] mislead the European commission33. According to the author, competition law .[A] should sever the new market powers[B] may worsen the economic imbalance[C] should not provide just one legal solution[D] cannot keep pace with the changing market34. Competition law as presently interpreted can hardly protect Facebook users because .[A] they are not defined as customers[B] they are not financially reliable[C] the services are generally digital[D] the services are paid for by advertisers35. The ants analogy is used to illustrate .[A] a win-win business model between digital giants[B] a typical competition pattern among digital giants[C] the benefits provided for digital giants ’customers[D] the relationship between digital giants and their usersText 4To combat the trap of putting a premium on being busy, Cal Newport, author of Deep Work: Rules for Focused Success in a Distracted World, recommends building a habit of “deep work”-the ability to focus without distraction.There are a number of approaches to mastering the art of deep work- be it lengthy retreats dedicated to a specific task; developing a daily ritual; or taking a “journalistic” approachto seizing moment of deep work when you can throughout the day. Whichever approach, the key is to determine your length of focus time and stick to it.Newport also recommends “deep scheduling” to combat constant interruptions and get more done in less time. “At any given point, I should have deep work scheduled for roughly the next mouth. Once on the calendar, I protect this time like I would a doctor’s appointment or important meeting”, he writes.Another approach to getting more done in less time is to rethink how you priorities your day – in particular how we craft our to-do lists. Tim Harford, author of Messy: The Power of Disorder to Transform Our Lives, points to a study in the early 1980s that divided undergraduates into two groups: some were advised to set out monthly goals and study activities; others were told to plan activities and goals in much more detail, day by day.While the researchers assumed that the well-structured daily plans would be most effective when it came to the execution of tasks, they were wrong: the detailed daily plans demotivated students .Harford argues that inevitable distractions often render the daily to-do list ineffective, while leaving room for improvisation in such a list can reap the best results.In order to make the most of our focus and energy, we also need to embrace downtime, or as Newport suggests, “be lazy”.“Idleness is not just a vacation, an indulgence or a vice; it is as indispensable to the brain as vitamin D is to the body …”[idleness]is, paradoxically, necessary to getting any work done,”he argues.Srini Pillay, an assistant professor of psychiatry at Harvard Medical School, believes this counterintuitive link between downtime and productivity may be due to the may our brains operate. When our brains switch between being focused and unfocused on a task, they tend to be more efficient.“What people don’t realise is that in order to complete these tasks they need to use both the focus and unfocus circuits in their brain,” says Pillay.36. The key to mastering the art of deep work is to .[A] keep to your focus time[B] list your immediate tasks[C] make specific daily plans[D] seize every minute to work37. The study in the early 1980s cited by Harford shows that .[A] distractions may actually increase efficiency.[B] daily schedules are indispensable to studying[C] students are hardly motivated by monthly goals[D] detailed plans may not be as fruitful as expected38. According to Newport, idleness is .[A] a desirable mental state for busy people.[B] a major contributor to physical health[C] an effective way to save time and energy[D] an essential factor in accomplishing any work39. Pillay believes that our brains’ shift between being focused and unfocused .[A] can result in psychological well-being[B] can bring about greater efficiency[C] is aimed at better balance in work[D] is driven by task urgency40. This text is mainly about .[A] ways to relieve the tension of busy life[B] approaches to getting more done in less time[C] the key to eliminating distractions[D] the cause of the lack of focus timePart BDirections:Read the following text and answer the questions by choosing the most suitable subtitles from the list A-G for each numbered paragraph (41-45). There are two extra subtitles which you do not need to use. Mark your answers on the ANSWER SHEET. (10 points)A.Just say itB.Be presentC.Pay a unique compliment, places, thingsE.Find the “me too”sF.Skip the small talkG.Ask for an opinionFive ways to make conversation with anyoneConversations are links, which means when you have a conversation with a new person a link gets formed and every conversation you have after that moment will strengthen the link.You meet new people every day: the grocery worker, thecab driver, new people at work or the security guard at the door. Simply starting a conversation with them will form a link.Here are five simple ways that you can make the first move and start a conversation with strangers.41、______________________________________________Suppose you are in a room with someone you don’t know and something within you says “I want to talk with this person”-this is something that mostly happens with all of us. You wanted to say something-the first word –but it just won’t come out, it feels like it is stuck somewhere. I know the feeling and here is my advice: just get it out.Just think: what is the worst that could happen? They won’t talk with you? Well, they are not talking with you now!I truly believe that once you get that first word out everything else will just flow. So keep it simple: “Hi”,“Hey”or “Hello”- do the best you can to gather all of the enthusiasm and energy you can , put on a big smile and say “Hi”。

2018年2月USACO铜级题2

2018年2月USACO铜级题2

USACO 2018 F EBRUARY C ONTEST , B RONZEP ROBLEM 2. H OOFBALLIn preparation for the upcoming hoofball tournament, Farmer John is drilling his cows (conveniently numbered , where ) in passing the ball. The cows are all standing along a very long line on one side of the barn, with cow standing units away from the barn (). Each cow is standing at a distinct location.At the beginning of the drill, Farmer John will pass several balls to different cows. When cow receives a ball, either from Farmer John or from another cow, she will pass the ball to the cow nearest her (and if multiple cows are the same distance from her, she will pass the ball to the cow farthest to the left among these). So that all cows get at least a little bit of practice passing,Farmer John wants to make sure that every cow will hold a ball at least once. Help him figure out the minimum number of balls he needs to distribute initially to ensure this can happen, assuming he hands the balls to an appropriate initial set of cows.INPUT FORMAT (file hoofball.in):The first line of input contains . The second line contains space-separated integers, where the th integer is .OUTPUT FORMAT (file hoofball.out):Please output the minimum number of balls Farmer John must initially pass to the cows, so that every cow can hold a ball at least once.SAMPLE INPUT:57 1 3 11 4SAMPLE OUTPUT:2In the above example, Farmer John should pass a ball to the cow at and pass a ball to the cow at . The cow at will pass her ball to the cow at , after which this ball will oscillate between the cow at and the cow at . The cow at will pass her ball to the cow at , who will pass the ball to the cow at , after which this ball will also cycle between the cow at and the cow at . In this way, all cows will be passed a ball at least once (possibly by Farmer John, possibly by another cow).It can be seen that there is no single cow to whom Farmer John could initially pass a ball so that every cow would eventually be passed a ball.Problem credits: Dhruv Rohatgi N 1…N 1≤N ≤100i x i 1≤≤1000x i i N N i x i x =1x =11x =1x =3x =3x =4x =11x =7x =4x =3x =。

2018USACO真题Platinum2

2018USACO真题Platinum2
Q
lines, each with either the string "YES" or "NO".
SAMPLE INPUT: 5 5 4 ##.## ##.## A.B.. ##.## ##.## 3 2 3 5 1 3 5 3 SAMPLE OUTPUT: NO YES NO NO To push the box to the position (3, 5), the cow just needs to move 3 spaces to the right. None of th Problem credits: Nathan Pinsker

USACO 2017 D P 2. P
B
C
,P
Bessie and her friends have invented a new game. The game is named accurately, but not particularly creatively. They call it the "Push A Box Around The Barn To Get It In The Right Spot And Don't Move The Hay" game (if you think that's excessive, you should see some of the variable names the cows use when they write code...) The barn can be modeled as an N × M rectangular grid. Some of the grid cells have hay in them. Bessie occupies one cell in this grid, and a large wooden box occupies another cell. Bessie and the box are not able to fit in the same cell at the same time, and neither can fit into a cell containing hay. Bessie can move in the 4 orthogonal directions (north, east, south, west) as long as she does not walk into hay. If she attempts to walk to the space with the box, then the box will be pushed one space in that direction, as long as there is an empty cell on the other side. If there is no empty cell, then Bessie will not be able to make that move. A certain grid cell is designated as the goal. Bessie's goal is to get the box into that location. Given the layout of the barn, including the starting positions of the box and the cow, and the target position of the box, determine if it possible to win the game. Note: This problem allows 512MB of memory usage, up from the default limit of 256MB. INPUT FORMAT (file pushabox.in): The first line has three numbers, N , M , and Q, where N is the number of rows in the grid and M is the number of columns.

2018英语二历年试题和答案

2018英语二历年试题和答案

2018 年全国硕士研究生入学统一考试管理类专业硕士学位联考英语试卷二Section I Use of EnglishDirections:Read the following text. Choose the best word(s) for each numbered blank and mark, A.B.C or D on ANSWER SHEET. (10 points)Why do people read negative Internet comments and do other things that will obviously be painful? Because humans have an inherent need to 1 uncertainty, according to a recent study in Psychological Science. The new research reveals that the need to know is so strong that people will 2 to satisfy their curiosity even when it is clear the answer will 3 .In a series of four experiments, behavioral scientists at the University of Chicago Booth School Of Business and the Wisconsin School of Business tested students' willingness to 4 themselves to unpleasant stimuli in an effort to satisfy curiosity. For one 5 , each participant was shown a pile of pens that the researcher claimed were from a previous experiment. The twist? Half of the pens would 6 an electric shock when clicked.Twenty-seven students were told which pens were rigged; another twenty-seven were told only that some were electrified. 7 left alone in the room, the students who did not know which ones would shock them clicked more pens and incurred more jolts than the students who knew what would 8 . Subsequent experiments replicated this effect with other stimuli, 9 the sound of fingernails on a chalkboard and photographs of disgusting insects.The drive to 10 is deeply ingrained in humans, much the same as the basic drives for 11 or shelter, says Christopher Hsee of the University of Chicago, a co-author of the paper. Curiosity is often considered a good instinct—it can 12 new scientific advances, for instance—but sometimes such 13 can backfire. The insight that curiosity can drive you to do 14 things is a profound one.Unhealthy curiosity is possible to 15 , however. In a final experiment, participants who were encouraged to 16 how they would feel after viewing an unpleasant picture were less likely to 17 to see such an image. These results suggest that imagining the 18 of following through on one's curiosity ahead of time can help determine 19 it is worth the endeavor. “Thinking about long-term 20 is key to miti gating the possible negative effects of curiosity,” He says. In other words, don't read online comments.1. A .resolve B. protect C. discuss D. ignore2. A refuse B. wait C. seek D .regret3. A .rise B. last C. mislead D. hurt4. A. alert B. tie C. expose D. treat5. A. message B. trial C. review D. concept6. A. remove B. weaken C. deliver D. interrupt7. A. Unless B. If C. Though D. When8. A. happen B. continue C. disappear D. change9. A rather than B. such as C. regardless D .owing to10. A. disagree B. forgive C. forget D. discover11. A. pay B. marriage C. food D. school12. A. begin with B. rest on C. learn from D. lead to13. A. withdrawal B. inquiry C. persistence D. diligence14. A. self-destructive B. self-reliant C. self-evident D. self-deceptive15. A. resist B. define C. replace D. trace16. A. predict B. overlook C. design D. conceal17. A. remember B. choose C. promise D. pretend18. A. relief B. plan C. outcome D. duty19. A. whether B. why C. where D. how20 .A. limitations B. Investments C. strategies D. consequences【答案】1. D resolve2. B seek3. C hurt4. B expose5. A trial6. B deliver7. C when8. D happen9. A such as 10. C discover11. B food 12. C lead to 13. A inquiry 14. D self-destructive 15. D resist16. D predict 17.A choose 18. B outcome 19. D whether 20. C consequencesSection II Reading ComprehensionPart ADirections: Read the following four passages. Answer the questions below each passage by choosing A, B, C or D. Mark your answers on ANSWER SHEET. (40 points)Text 1It is curious that Stephen Koziatek feels almost as though he has to justify his efforts to give his students a better future.Mr. Koziatek is part of something pioneering. He is a teacher at a New Hampshire high school where learning is not something of books and tests and rote memorization, but practical, reports staff writer Stacy Teicher Khadaroo in this week’s cover story. When did it become accepted wisdom that students should be able to name the 13th president of the United States but be utterly bamboozled by a busted bike chain?As Koziatek knows, there is learning in just about everything. Nothing isnecessarily gained by forcing students to learn geometry at a graffiti desk stuck with generations of discarded chewing gum. They can also learn geometry by assembling a bicycle.But he’s also found a kind of insidious prejudice. Working with your hands is seen as almost a mark of inferiority. Schools in the family of vocational education “have that stereotype ... that it’s for kids who can’t make it academically,” he says.On one hand, that viewpoint is a logical product of America’s evolution. Manufacturing is not the economic engine that it once was. The job security that the US economy once offered to high school graduates has largely evaporated. More education is the new mantra. We want more for our kids, and rightfully so.But the headlong push into ba chelor’s degrees for all – and the subtle devaluing of anything less – misses an important point: That’s not the only thing the American economy needs. Yes, a bachelor’s degree opens more doors. But even now, 54 percent of the jobs in the country are middle-skill jobs, such as construction and high-skill manufacturing, according to the National Skills Coalition, a nonprofit advocacy group. But only 44 percent of workers are adequately trained.In other words, at a time when the working class has turned the country on its political head, frustrated that the opportunity that once defined America is vanishing, one obvious solution is staring us in the face. There is a gap in working-class jobs, but the workers who need those jobs most aren’t equipped to do them. Koziatek’s Manchester School of Technology High School is trying to fill that gap.Koziatek’s school is a wake-up call. When education becomes one-size-fits-all, it risks overlooking a nation’s diversity of gifts.21. A brokan bike chain is mentioned to sh ow students’l ack ofA.mechanical memorizationB.academic trainingC.practical abilityD.pioneering spirit22.There exists the prejudice that vocational education is for kids whoA.are financially disadvantagedB.are not academically successfulC.have a stereotyped mindD.have no career motivation23.We can infer from Paragraph 5 that high school graduatesA.are entitled to more “educational privileges”B.are reluctant to work in manufacturinged to have more job opportunitiesed to have big financial concerns24.The headlong push into bachelor’s degrees for allA.helps create a lot of middle-skill jobsB.may narrow the gap in working-class jobsC.is expected to yield a better-trained workforceD.indicates the overvaluing of higher education25.The author’s attitude toward Koziate’s school can be described a sA.supportiveB.disappointedC.tolerantD.cautiousTest 2While fossil fuels – coal, oil, gas –still generate roughly 85 percent of the world’s energy supply, it’s clearer than ever that the future belongs to renewable sources such as wind and solar. The move to renewable is picking up momentum around the world: They now account for more than half of new power sources going on line.Some growth stems from a commitment by governments and farsighted businesses to fund cleaner energy sources. But increasingly the story is about the plummeting prices of renewable, especially wind and solar. The cost of solar panels has dropped by 80 percent and the cost of wind turbines by close to one-third in the past eight years.In many parts of the world renewable energy is already a principal energy source. In Scotland, for example, wind turbines provide enough electricity to power 95 percent of homes. While the rest of the world takes the lead, notably China and Europe, the United States is also seeing a remarkable shift. In March, for the first time, wind and solar power accounted for more than 10 percent of the power generated in the US, reported the US Energy Information A dministration.President Trump has underlined fossil fuels –especially coal –as the path to economic growth. In a recent speech in Iowa, a state he won easily in 2016, he dismissed wind power as an unreliable energy source. But that message did not play well with many in Iowa, where wind turbines dot the fields and provide 36 percent of the state’s electricity generation – and where tech giants such as Facebook, Microsoft, and Google are being attracted by the availability of clean energy to power their data centers.Th e question “what happens when the wind doesn’t blow or the sun doesn’t shine?” has provided a quick put-down for skeptics. But a boost in the storage capacity of batteries, and a dramatic drop in their cost, is making their ability to keep power flowing around the clock more likely.The advance is driven in part by vehicle manufacturers, who are placing big bets on battery-powered electric vehicles. Although electric cars are still a rarity on roads in 2017, this massive investment could change the picture rapidly in coming years.While there’s a long way to go, the trend lines for renewable are spiking. The pace of change in energy sources appears to be speeding up – perhaps just in time to have a meaningful effect in slowing climate change. What Washington does –or doesn’t do –to promote alternative energy may mean less and less at a time of a global shift in thought.26.The word “plummeting” (line3.para2) is closest in meaning to .A.risingB.fallingC.changingD.stabilizing27.According to Paragraph 3.the use of renewable energy in America .A.is progressing notablyB.is as extensive as in EuropeC.faces many challengesD.has proved to be impractical28.It can be learned that in Iowa .A .wind is a widely used energy sourceB.wind energy has replaced fossil fuelsC.tech giants are investing in clean energyD.there is a shortage of clean energy supply29.Which of following in true about clean energy according to paragraphs 5&6?A.Its application has boosted battery storageB.It is commonly used in can manufacturing.C.Its continuous supply is becoming a reality.D .Its sustainable exploitation will remain difficult.30.It can be inferred from the last paragraph that renewable energy_ .A.will bring the US closer to other countriesB.will accelerate global environment changeC.is not really encouraged by the US governmentD is not competitive enough with regard to its cost26题【B】falling解析:本题为词汇题,词汇题的解题,在于语境的理解。

2018年上海高三年级英语二模翻译汇总

2018年上海高三年级英语二模翻译汇总

2018 上海英语高三二模翻译汇总宝山72. 我对这场比赛的结果抱乐观态度。

(optimistic )I am optimistic about the result of the game /match.73. 许多人把迟到看作是一个小问题,其实不然。

(think )Many people think of being late as a small problem, but in fact it ’s not./it can have serious consequences.74. 无人驾驶技术解决了人们的困惑,使开车打电话成为可能。

(⋯it ⋯)Driverless technology solves people's puzzle and makes it possible to make a phonecall /talk on the phone while driving.75. 人生中最可怕的不是你即使努力了仍一事无成,而是碌碌无为却以平凡可贵安慰自己。

(...not...but... )The most horrible/terrible/ dreadful/ fearful/ frightening/frightful thing that canhappen in your life is not that you achieved/accomplished nothing even though youtried, but that you do nothing at all/give up and tell yourself it is precious to be justordinary .崇明72. 何不利用这宜人的天气出去野餐呢?(advantage)73. 当你对情况一知半解时,不要随意发表见解。

(knowledge)74. 到底是什么促使你放弃了这么稳定的工作,来到这个偏远地区保护野生动物?(it)75. 人工智能正以如此快的速度改变着整个世界,你很难预测未来的生活究竟会是什么样子。

usaco中文译题

usaco中文译题

Greedy Gift Givers贪婪的礼物送礼者译by tim green对于一群要互送礼物的朋友,你要确定每个人送出的礼物比收到的多多少(and vice versa for those who view gift giving with cynicism)。

在这一个问题中,每个人都准备了一些钱来送礼物,而这些钱将会被平均分给那些将收到他的礼物的人。

然而,在任何一群朋友中,有些人将送出较多的礼物(可能是因为有较多的朋友),有些人有准备了较多的钱。

给出一群朋友,没有人的名字会长于14 字符,给出每个人将花在送礼上的钱,和将收到他的礼物的人的列表,请确定每个人收到的比送出的钱多的数目。

IMPORTANT NOTE测试系统是Linux 符合标准的Unix 的协定。

用'\n'作为行的结束。

这和Windows 系统用'\n' 和'\r'作为行的结束是不同的。

你的程序不要被这困住了。

PROGRAM NAME: gift1INPUT FORMATSAMPLE INPUT (file gift1.in)5davelauraowenvickamrdave200 3lauraowenvickowen500 1daveamr150 2vickowenlaura0 2amrvickvick0 0OUTPUT FORMAT输出NP 行每行是一个的名字加上空格再加上收到的比送出的钱多的数目。

对于每一个人,他名字的打印顺序应和他在输入的2到NP+1行中输入的顺序相同。

所有的送礼的钱都是整数。

每个人把相同数目的钱给每位要送礼的朋友,而且尽可能多给,不能给出的钱被送礼者自己保留。

SAMPLE OUTPUT (file gift1.out)dave 302laura 66owen -359vick 141amr -150Your Ride Is Here你要乘坐的飞碟在这里译by tim green一个众所周知的事实,在每一慧星后面是一个不明飞行物UFO。

2018年度国外数学竞赛试题翻译汇编

2018年度国外数学竞赛试题翻译汇编
2018 年 ARML 数学竞赛 …………………………………………… 57 2018 年美国数学邀请赛(AIME) I …………………………………… 66 2018 年美国数学邀请赛(AIME) II ………………………………… 69 2018 年美国数学奥林匹克 …………………………………………… 72 2018 年美国初中数学奥林匹克 ……………………………………… 73 2018 年美国 IMO 代表队选拔考试 ………………………………… 74 2018 年美国 TSTST …………………………………………………… 76 2018 年美国第 20 届 ELMO ………………………………………… 78 2018 年美国第 20 届 ELMO 预选题 ………………………………… 80 2018 年第 20 届美国旧金山湾区数学奥林匹克 …………………… 83 2017-2018 年度 USAMTS …………………………………………… 86 2018 年美国女子数学奖学金竞赛(决赛) …………………………… 91 2017-2018 年度威斯康星数学、科学与工程学人才选拔 ………………… 92 2018 年奥地利数学奥林匹克 ………………………………………… 96 2018 年澳大利亚数学奥林匹克 ……………………………………… 99 2018 年澳大利亚、英国 IMO 国家队联合训练考试 ………………… 89 2018 年白罗斯数学奥林匹克 ………………………………………… 101 2018 年波黑数学奥林匹克(地区级) ………………………………… 105 2018 年波黑 EGMO 代表队选拔考试 ……………………………… 107 2018 年波黑 JBMO 代表队选拔考试 ………………………………… 108 2018 年巴西数学奥林匹克 …………………………………………… 109 2018 年巴西 IMO 代表队选拔考试 ………………………………… 111
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

USACO 2017年首轮月赛金级题2
粉刷谷仓
John有个大农场。

农场上有N个谷仓(1 ≤ N ≤ 105),其中一部分谷仓已经被粉刷过,另一部分还未被粉刷。

John想把剩下的谷仓也粉刷了。

现在John只有三种颜色的涂料。

如果相邻的两个谷仓粉刷的颜色相同,Bessie会搞晕的。

所以,他要尽量避免这种情况发生。

现在确定的是N个谷仓之间没有任何闭环存在。

也就是说,在任意两个谷仓之间,至多有一条路相通。

问:John粉刷剩下的谷仓的组合方式有多少种?
INPUT FORMAT (file barnpainting.in):
第一行有两个整数N和K(0≤ K ≤ N),分别代表农场的谷仓数和已经被粉刷的谷仓数。

其后N-1行,每一行都有两个整数x和y(1 ≤ x, y ≤ N, x ≠ y), 分别代表通往谷仓x和谷仓的路的数量。

再往后的K行,每一行都有两个整数b(1≤ b ≤ N)和c(1≤ c ≤ 3),表示谷仓b刷了颜色c。

OUTPUT FORMAT (file barnpainting.out):
在保证相邻的谷仓颜色不同的前提下,计算共有多少种方法可以粉刷其余的谷仓,SAMPLE INPUT:
4 1
1 2
1 3
1 4
4 3
SAMPLE OUTPUT: 8。

相关文档
最新文档