If it walks like a duck and quacks like a duck, it must be a duck.
如果它像鸭子一样走路,像鸭子一样呱呱叫,那它一定是一只鸭子。
It isn't like a duck to water to learn a foreign language, so you must work hard.
学习一门外语不像鸭子会游泳那么简单,必须努力才行。
Affectionately known as "duck typing" (i.e., if it waddles like a duck and quacks like one, then it must be a duck!), polymorphism in Ruby is just a matter of matching method names.
Ruby中的多态性被亲切地称为“ducktyping”(意思是,如果它走起路来像鸭子,叫起来也像鸭子,那么它一定是鸭子!),这种多态性只是对方法名进行匹配的问题。
"If it looks like a duck, and quacks like a duck, we have at least to consider the possibility that we have a small aquatic bird of the family Anatidae on our hands," said Rose, quoting Douglas Adams.
“如果它长得像鸭子,而且像鸭子般呱呱叫,那我们至少得考虑这种可能性:我们手中得有只鸭科的小水鸟”,洛兹引述道格拉斯·亚当斯的话说。
The restaurant itself is a little ramshackle, but the sublime duck makes it a culinary experience to savour .
这家店店面本身十分朴素,但独特的烤鸭使这富有令人难忘的美味体验。
So, traditional hats might the cool thing to wear in Paris, but thegood news hasn’t yet reached the duck farms of Aussats, a village sosmall that it doesn’t register on a GPS.
所以,传统帽子在巴黎或许是个很酷的玩意儿,但奥萨特养鸭场的人们却对这件好事闻所未闻,这个村庄太小,没有GPS。
The Li men jostle to sell me supper, all of it live: white-breasted waterhens, little egrets, a black-crowned night heron and a spot-billed duck, the only duck where male and female look alike.
黎族人争相向我兜售晚餐,全部是活的:白胸苦恶鸟,小白鹭,黑冠夜鹭,斑嘴鸭,这是唯一一种雌雄看起来都很像的鸭子。
I figured the duck tongues were a sort of test, so I made it a point to look unfazed. Excited even.
我猜她拿鸭舌头当某种测试吧,所以我一副大无畏的表情,甚至有点兴奋。
It matters nothing if one is born in a duck-yard, if one has only lain in a swan's egg.
出生在鸭窝里有什么关系,只要是从天鹅蛋里孵化出来的就行了。
We re-carpeted the hall in a thin stripe of duck egg and off white which gives it a more beachy light look.
我们重新装饰了门廊的地面,让这里看起来更加轻松,更有海滩的感觉。
This hungry fox ended up a victim of the sub-zero temperatures when it chased a duck across an ice-covered lake - and froze to death.
一只饥饿的狐狸在结冰的湖面追赶野鸭,结果冻死在冰点下的水中。 图片由摄影师蒂姆·伍德科克于南安普顿的汉特斯附近的阿什利特水塘处拍得。
'I know what "it" means well enough, when I find a thing,' said the Duck: 'it's generally a frog or a worm.
我发现了什么吃的东西时,当然知道‘这’是指什么。
The researchers, it seems, worked out that a meal of prawn crackers, crispy duck, chicken balls and spring rolls contained 2.823 calories and 132.5g fat - "the equivalent of a small wine glass".
看起来那些调查者们算出一餐包括炸虾片、香酥鸭、鸡脯丸子和春卷的饭含2.823卡路里的热量和132.5g的脂肪,而这,等同于一小酒杯的量。
Ruby USES what is affectionately referred to as "duck typing" - if it accepts a "quack" message, it must be a duck.
Ruby使用所谓的“ducktyping”——也就是说,如果它接受“鸭叫”消息,那么它一定是鸭子。
On a farm, if you see a white duck, it presages a good harvest and prosperity.
一个农场,如果您看到一个白色鸭,它预示着一个好的收成和繁荣。
I remembered that once when I was growing up, my father took a feather from a wild duck he'd shot and tied it on a hook and gave it to me.
我想起童年时期,有一次我父亲从他射下来的一只野鸭身上拔下一根羽毛,把羽毛系在鱼钩上递给我。
The different duck looks at the animal. It is a big white bird. It has a long neck.
怪鸭子看了看那只动物,是一只又大又白的鸟,脖子长长的。
We thought it would take a couple of years for him to reach this level, but he took to the challenge like a duck to water.
我们本来觉得他得好几年才能达到现在的水平,但他接受挑战如鱼得水。
It features a slice of crispy Peking duck skin and juicy lean meat nestled in a bun and topped with slices of onion, tomato, cucumber, lettuce and the all-important plum sauce.
北京烤鸭的酥皮和多汁瘦肉配上汉堡胚,洋葱、番茄、黄瓜、生菜层层覆盖烤鸭,而苏梅酱则是最后的点睛之笔。
Mediocrity like a duck, as it refuses to refuse a life of ease, but rather challenging environment, challenging the sky.
它拒绝像鸭子那样碌碌无为,拒绝安逸的生活,而宁愿挑战环境,挑战天空。
If it looks like a duck, chances are it thinks like a duck.
如果他们看起来像鸭子,可能他们的思维也和鸭子一样。
It is a direct application of a popular idea: If it walks like a duck and quacks like a duck, it must be a duck.
它直接应用了一个很流行的理念:走起路来象鸭子和叫起来象鸭子的,那就一定是只鸭子。
If something looks like a duck, sounds like a duck, walks like a duck and there is enough evidence to prove it's a duck, then that's what we'll call it.
如果一个动物很像鸭子,叫声和鸭子一样,走路也像鸭子,同时有足够的证据显示它就是鸭子,那我们就叫它鸭子。
Then dip a slice of duck in the sauce and put it on a pancake. Next, put some green Onions on it and roll the pancake. Finally you can eat it.
然后把一块鸭肉在酱里蘸一下,把它放在一张薄片烙饼上,然后放上一颗葱卷起来,最后可以吃了!
Depending on whether an observer sees a duck or a rabbit first and how fast it sees the other is an indicator of how creative you are, and how fast your brain works.
可以根据观图者是先看到鸭子、还是先瞧见兔子来判别创造力是否丰富,两物间切换速度的快慢可以判别脑子转速的快慢。
Certainly, the timing fits to a tee, and as stated here regularly in the past: if it walks like a duck and quacks like a duck then it surely is not a peacock.
确实,时机正合适,正如我们一直在这唠叨的:如果某只秒走起来向鸭子,叫起来嘎嘎的,那么它肯定不是只孔雀。
If one wants to live like a duck to water, besides his or her ability, apple-polishing is very important, I hope I can get a handle on it.
如果一个人想混的如鱼得水,除了自身的能力外,拍马屁也很重要,我很希望我自己也可以得到要诀。
If one wants to live like a duck to water, besides his or her ability, apple-polishing is very important, I hope I can get a handle on it.
如果一个人想混的如鱼得水,除了自身的能力外,拍马屁也很重要,我很希望我自己也可以得到要诀。
应用推荐