He's here to heal. Child of the cosmos, Mind traveling through Warm sands and subway tracks Humming lullabies in broken Arabic, like"Ahibak,akhi"*(*ahibak,akhi: I love you,my brother) And it's been far from easy On my clumsy days;
VOA: special.2009.04.17
s1 I have a variable called s1 and it's char * of type char * so here we go.
我有一个变量,它的类型是。
S**t, I mean. It's pretty bad. I mean.
我的意思是,非常糟糕。
Based on the lessons we've been telling if I say *, you know what I have a computer.
基于我们讲过的课程,如果我指明,我有一台计算机。
Ah, n times, because for each value of i, I'm going to do that m thing, n*m so that is, close to what you said, right?
因此这就和你说的差不多了对不对?,这个问题的复杂度为,让我写下来,是-对不对,是?
I have *.
我得到*
Let's multiply both sides by 2, I'll get 2q1* is equal to a - c over b - q1*.
等式两边同时乘以2,得到,2q1*=/b-q1
*10^-19 That is 1.6 times 10 to the minus 19 and I write joules.
。,然后我又写了焦耳。
char* Because I've said that char Star is really just the true version of this.
因为我说过,实际上是字符串的真实版本。
char * s1 Then I go ahead and declare a char * called s1.
然后我声明。
Well, I use the * notation.
嗯,我使用*符号。
> David: So the, why do I need the *?
>,大卫:那么,为什么我需要那个*符号?
Now, I've taken off the training wheel of the CS50 Library and I'm just flat out saying char *. No more strings.
现在,我开始了CS50库的培训,我只指明char,*,没有更多的字符串。
So if Player I chooses S1*, Player II will want to choose S2* since that's her best response.
所以当参与人I选择S1*时,参与人II就会选择最佳对策S2
If Player II is playing S2*, Player I will want to play S1* since that's his best response.
如果参与人II选择S2,参与人I就会选最佳对策S1
This is copy2.c. At the very beginning I, again, demand say something and then I declare s1 to be a string, aka char *, and I store in s1 the string the user types in.
这是copy2。c,在开头打印一句话,然后声明s1是一个字符串,也叫做char,*,然后把用户输入的字符串存储在s1中。
I have 3 q1* is equal to a - c over b; and finally divide by 3 q1* is equal to a - c over 3b.
q1*= /b,最后两边同除以3得,q1*=/3b
int *x So I have int *x.
所以我用。
If I reduce that it would be 3 plus t of b minus 3, so in general 3*k+t this is 3 k plus t of b minus k. OK.
把b减去一个,在外面加个3就可以了,因此也就是。
I'll leave the algebra there, transfer it up here, q1* = q2* = a - c over 3b.
先把算式留在那好了,我在这里再抄一遍吧,q1*=q2*=/3b
I write 1.0 times 1.6. Even that I can do in my head.
写下1。0*1。6,即使我可以在头脑中想象。
*2=6 So I have three times two is six.
由于。
Now get int *y so now I'll use the board for things I can't really draw very well with the keyboard so what does the memory of my program look like at the moment?
现在,=,int,*y,现在我使用黑板,我用键盘画的不是很好,那么此刻,我程序中的内存看起来像什么?
I'm going to call it int *y enter or, sorry, semicolon, and then what if I do this?
我把它叫做int,*y,回车,抱歉,分号,如果我这样处理,会发生什么?
int No. Even though the key word has changed from char to int, the * is the same and the fact that I've got a * there is saying this is a pointer to an int or a pointer to a char pointers are always the same size on a computer.
不,即使即使关键字从char变成了,指针的大小还是一样的,我用*表示这是一个int型指针,而不是char型指针,在同一台机子上,它们的大小是一样的。
So taking advantage of the fact that we know S1 is equal to S2 I can simplify things by making S1* equal to S2*.
我们利用S1=S2这个等式,这样用S1*=S2*可以化简了
Well, go back to what I did before.
我会用a*a的b-1次方的形式来表达。
So similarly, I would find that ?2 2 equals 1 plus B S1 and this is the best response of Player II, as it depends on Player I's choice of effort S1.
同理可得?2等于1+B*S1,?2是参与人II的最佳对策,因为它与参与人I的策略S1有关
Indeed, swap in your printout there is just defined as now taking *a and *b and then it also uses the * later, but we'll come back to what the different uses of the * means, but for now I claim conceptually it just means swap has access to the locations of its parameters.
的确,在打印资料中的swap被定义为,携带*a和*b,之后它也是带*号的,但是我们将说明*的不同用法,现在,我断言swap可以,使用参数的地址。
And I can solve them, and if I solve them out, I'm going to get something like, let me just be careful, I'm going to get something like: 1 minus B S1* is equal to 1, or S1* equals S2* is equal to 1 over .
我们都会解这个方程,如果解完方程,我们会得到,我得仔细点别算错,我们会得到,1-BS1*=1,或S1*=S2*=1/
应用推荐