• And if that's true is everything in the string, starting at the first element and removing the last element, a palindrome?

    如果是相同的话,是不是字符串中的所有从第一个元素开始,并且删除最后一个元素后?

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • And then hash character takes in any string or character, single character, gives me back a number. Notice what I do.

    然后哈希接受任何字符串或字母,单个字符,返回给我一个数字,注意我要做什么。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Is it is just like a string of words or-- >> What does-- what does what mean? A string?

    字符串?单词?还是?,>>你刚刚说什么?,一个字符串

    哈佛公开课 - 计算机科学课程节选

  • Now I could have made a key, keys don't have to be strings, but as it happened, I didn't.

    现在我可以建立一个键了,键并不一定是字符串,但这儿既然已经是字符串了。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Otherwise I'm going to check to see is the first and last, there's that - 1 indexing, is the first and last element of the string the same?

    是第一个还是最后一个,这就是这边-1的索引内容,这个字符串的第一个,和最后一个的内容是否相同呢?

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Now, if I've asked the user for a string and then a moment later I ask the user for another string, well, they're going to end up in different locations in memory just by nature of get string.

    现在,如果我要用户输入一个字符串,一会儿之后我要用户输入另一个字符串,他们最终是在,不同的内存地址中。

    哈佛公开课 - 计算机科学课程节选

  • STUDENT: Good question. Sounds like a reasonable guess How in the world am I going to compare a string to a number?

    学生:不可闻的声音:,很好的问题,听起来像一个很合理的猜测,我到底该怎么对一个字符串,和一个数字进行比较呢?

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • If you know you're not gonna output a full string %C but a single character, percent C will get that job done.

    如果你不想输出一个完整的字符串,而是输出一个字母,就要用到。

    哈佛公开课 - 计算机科学课程节选

  • That is the address in memory in the heap of the first byte that the user typed in.

    那是用户输入的字符串一个字节,内存中堆的地址。

    哈佛公开课 - 计算机科学课程节选

  • Even though my statement said enter a number, in particular, raw input here simply takes in a set of characters and treats it as a string.

    即使我的陈述说的是应该输入一个数字,实际上,这里的原始输入会被当做一个字符,的集合来提取并被当做一个字符串来对待。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • When you've been typing in words to the keyboard like your name or any word that you're trying to provide to the user, a string really looks like this.

    当你们通过键盘键入单词,比如你的名字,或者你想提供给用户的任何单词,一个字符串实际上看起来就是这样。

    哈佛公开课 - 计算机科学课程节选

  • So, let's do a little sanity check now and let's try to demonstrate as much I now claim I'm going to capitalize the copy of the string I just made.

    多以,让我们做一个检查,然后做一个演示,现在我声称,我要利用那个字符串的拷贝。

    哈佛公开课 - 计算机科学课程节选

  • It's just a chunk of characters back to back to back so this is storing at the very first location in the string what?

    它只是一串紧邻的字母串,所以它把什么存储在,字符串的第一个地址下?

    哈佛公开课 - 计算机科学课程节选

  • We have some set of things we want to do with strings, and different set of things we want to do with numbers.

    这就对了,我们有一个可以对字符串,进行操作的方法集,还有另外一个不同的。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Just the first one or more generally the address of the first one and then, man, I'll just figure it out from there where the rest of the letters are because by definition of a string, they're back to back to back.

    只需要第一个字节的地址,然后,我可以指出之后的,剩下的字母,因为通过一个字符串的定义,它们是紧邻的。

    哈佛公开课 - 计算机科学课程节选

  • You can't just take a quoted string back to back with another quoted string so you'd get some kind of compiler error.

    你不能让一个引起来的字符串跟另一个引起来的字符串,背靠背,这样编译就会出错。

    哈佛公开课 - 计算机科学课程节选

  • If I want a copy of the string, I've got to whip out my week 1 skills of just iterating with a four loop from left to right and make copies of those characters.

    我需要那个字符串一个拷贝,我使用,第一周的技巧,从左到右做四次迭代,然后复制这4个字符。

    哈佛公开课 - 计算机科学课程节选

  • Last time we used printf generally to print a static string, like a hardcoded string, like "David," just for example's sake.

    上次我们通常用“printf“,来打印一个静态的字符串,像硬编码的字符串“David“,这只是个例子。

    哈佛公开课 - 计算机科学课程节选

  • If you give me a number and a string, I'm going to concatenate them together, it's really different operations, but nonetheless, it's what it's going to do.

    如果给的输入是一个数字和一个字符串,我将会把它们连接在一起,这实在是不正确的操作,但是无论如何,它就是会去这么做。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • - And because I'm writing out a string that's the same length -- -- my strings aren't getting shorter -- it's creating this illusion of some animation.

    因为我写了一个长度相同的字符串-,我的字符串不会变的更短-,它生成一个动画幻觉。

    哈佛公开课 - 计算机科学课程节选

  • So, I'm getting a string and so what really am I doing in this line of code?

    那么,我得到一个字符串,这行代码实际上是干什么的呢?

    哈佛公开课 - 计算机科学课程节选

  • First, I'm going to do a sanity check strlen so we've used string length, strlen, before.

    首先,我先做一个检查,我们以前使用过字符串长度函数。

    哈佛公开课 - 计算机科学课程节选

  • Notice by the way, there's that nice speck true going on saying put a string here.

    在这里说放一个字符串在这儿有点小问题,如果是回文的话那么它将会返回真值。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • I want an actual copy in memory so that that string is in two different places.

    我想要在内存中有一个拷贝,把字符串存储在,两个不同的地方。

    哈佛公开课 - 计算机科学课程节选

  • There's a whole bunch of blocks that we'll look at in more fun detail on Friday but I'm going to pick the easiest one here and I'm going to type Hello CS50 in this string, "Hello CS50", zooming in say how nice the puzzle pieces are nicely interlocked?

    今天我们看到的各种图块,到下周五我会仔细讲解其中的精妙之处,但今天我只想举一个最简单的例子,我要在这儿键入字符串,放大窗口,然后看看这漂亮的图形和文字,是如何美妙地连结在一起的?

    哈佛公开课 - 计算机科学课程节选

  • I got string and it went along but what does that actually mean?

    我有一个字符串……,但是这意味着什么?

    哈佛公开课 - 计算机科学课程节选

  • Strings are captured in Python with an open quote and some sequence of characters followed by a closed quote.

    字符串在Python中,是以一个开引号开始,然后后面是一系列的字符,以一个尾引号结束。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • You can treat a string as though it's an array because it really is.

    你可以把一个字符串当做一个数组处理,因为它的确是一个数组。

    哈佛公开课 - 计算机科学课程节选

  • This is a sentence or string phrase that has been encrypted.

    这是一个被加密的句子或字符串短语。

    哈佛公开课 - 计算机科学课程节选

  • And it boils down to modifying the format string with just a simple number.

    它归结于是用一个简单的数字来,修改字符串的格式。

    哈佛公开课 - 计算机科学课程节选

$firstVoiceSent
- 来自原声例句
小调查
请问您想要如何调整此模块?

感谢您的反馈,我们会尽快进行适当修改!
进来说说原因吧 确定
小调查
请问您想要如何调整此模块?

感谢您的反馈,我们会尽快进行适当修改!
进来说说原因吧 确定