So what would I want to do? I'd like to somehow walk down each of the digits one at a time and add them up. Ah, that's a looping mechanism, right? I need to have some way of walking through them.
去取这个数的,每个数字然后把他们加起来,啊,这是个循环机制对不对?,我得找到一个遍历它们的方法,一种简单的方法可能。
That's down... probably about 50 blocks or so, 40 blocks. I'm going to walk down there. So I just like to walk.
动物园在离这里四五十个街区远的地方。我要走过去。我只是喜欢散步。
In fact, there's a very famous book called A Random Walk Down Wall Street, that was one of the first to make this hypothesis.
实际上,有一本很著名的书,叫做在华尔街上随机漫步,这本书是最早提出这种假设的先驱者之一。
You need to walk down the stairs and then up the stairs.
要被迫上下楼。
Most of the time I walk down Fifth Avenue with my mouth just watering
很多时候,我在第五大道都是边逛边馋涎欲滴,
I think for most normal people who just walk down the streets, I think,
我想对于只是走在街上的大部分普通人来说,
and walk down in to Holland Park, some beautiful houses, stuff around there.
走在荷兰公园里,观看漂亮的房子,欣赏附近的事物。
And I mean, there's... you can walk down Sproul Plaza and you know,
你可以去史鲍尔广场散步,
Walk. I like to go to the zoo. As a matter of fact, I'm walking down to the zoo right now.
散步。我喜欢去动物园。其实,我现在正要去动物园呢。
If you walk further down to the Strand, there's quite a lot of interesting things to do there.
如果你沿着河岸走远一点,那里有很多可做的事情。
I think he lives here. I've seen him walk up and down the street a few times.
我想他住在这儿。我在路上见过他几次。
but just to walk up and down like Canal Street, different streets like that,
到类似坚尼街的街上走走,
take a little walk down round Portobello Road.
绕着这条大街散步。
Well let's see. My fall back is, I could just do linear search, walk down the list one at a time, just comparing those things. OK. So that's sort of my base. But what if I wanted, you know, how do I want to get to that sorted list? All right?
我只能做线性搜索了,一次遍历一遍列表,一个一个比较,但如果我想要,那怎样得到有序的列表呢?,现在的一个问题是,我们排序之前?
Simply walk down that list.
执行一个直线序列的程序。
应用推荐