All right, so that notion of abstraction and we're going to come back to multiple times -- during the term-- and it's not just abstraction, -- it's the idea of a specification.
现在就试试,这就是抽象的概念,我回过来说,我们将要多次提到这个术语。
You have to pass it as input to another function, as you'll see as possible in problem's Set One specification, but it's ultimately up to you.
你需要把它传给另一个函数当入参,就像你们将,在习题集1中可能看到的,但它最终取决于你。
What do I need for those writers to all interact together? I need a specification.
这个比方的意义什么呢?,我需要怎么做才能使。
So one of the things I want you to notice here is that testing and debugging are not the same thing. When we test, we compare an input output pair to a specification.
这里我想大家注意的一件事,就是测试和调试是不同的两件事情,我们测试的时候,我们把输入输出,跟程序的规格说明书对比下。
Before we do that, or as you do that, let's look at Fib 1. The key thing to notice about Fib 1 is that it has the same specification as Fib.
我们做之前,或者当你在思考的过程中,让我们看看Fib,1,Fib1重要注意的,关键的一点就是,他和Fib的格式描述是一样的。
And notice, by the way, if I do that, and I type sqrt and open the paren, ah-ha! It shows me what the creator, in this case actually I stole this from John so what Professor Guttag put up as his specification for this piece of code.
它需要什么养的输入和其它我想传达的信息,如果我这么做了,我将会到这里打上sqrt并且加上括号,啊哈!这里告诉我这段程序的创建者,事实上这是我是从约翰那里偷来的,所以也就是Guttag教授在它的。
应用推荐