From 808106c1c2b707c57cf289a50f271beadcebdd62 Mon Sep 17 00:00:00 2001 From: Jidong Xiao Date: Mon, 8 Jan 2024 00:14:00 -0500 Subject: [PATCH] line break --- lectures/01_introduction/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lectures/01_introduction/README.md b/lectures/01_introduction/README.md index 6182fb5..0eb86d8 100644 --- a/lectures/01_introduction/README.md +++ b/lectures/01_introduction/README.md @@ -274,7 +274,7 @@ object. There are several ways of constructing string objects: 3. Reading stops either at the end of the input or upon reaching the next white-space character (without reading it in). - The (overloaded) operator ’+’ is defined on strings. It concatenates two strings to create a third string, without changing either of the original two strings. - The assignment operation ’=’ on strings overwrites the current contents of the string. -- The individual characters of a string can be accessed using the subscript operator [] (similar to arrays). +- The individual characters of a string can be accessed using the subscript operator [] (similar to arrays). – Subscript 0 corresponds to the first character. – For example, given std::string a = "Susan"; Then a[0] == 'S' and a[1] == 'u' and a[4] == 'n'. - Strings define a special type string::size_type, which is the type returned by the string function size()