It has a test in it, which is that while, while something is true, do something, but I want to keep doing it.
也有个测试在里面,也就是那个当,当一件事情为真的时候,做一些操作,但是我想一直进行判断。
I've got one test there, and then I've just got one thing to do here, which has got a subtraction and a multiplication.
这儿有一个比较,然后在一个基本步骤里,做了一个减法和一个乘法两个基本操作。
Is there anybody here who has actually, in any sort of situation, ? taken a Rorschach test?
不管出于什么原因,你们有人真的做过,罗夏测验吗?
And then it has a strange thing called ELIF, which is simply short for else/if in a second test.
然后代码做了一个奇怪的,叫做ELIF的事情,也就是else/if的简写,这是第二个测试。
I don't have to go read what it printed out in the screen. This has returned a value that I can use. Because I could do a test to say, is this a return value? If it's not, I'll do something else with it. So the binding is still there, it simply doesn't print it out.
我不想读到屏幕中打印出来的这行字,程序返回过一个我能够使用的值,因为我可以做个小测试,来说明这是否是返回的值,如果不是,我可以做一些其它的事,而这个绑定依然在这儿,没有打印任何东西。
First one, when I write a piece of code, especially code that has branches in it, when I design test cases for that piece of code, I should try and have a specific test case for each possible path through the code.
第一点,当我们写代码的时候,尤其是一些含有分支语句的代码的时候,当我为这些代码,设计测试用例的时候,我应该为每一个可能的程序路径,都设计一个特别的用例。
应用推荐