Week 12: Working with text
C code typing course. 21 wpm, 93% accuracy.
In C, text lives inside double quotes. Two string literals placed side by side are joined into one string by the compiler. This is different from the plus sign, which does not join text in C. A period . reaches a field inside a struct. This week you practice typing ", . and + on the US English layout.
What you will learn
On the US English layout:
": the ’ key with Shift. Press Shift with the opposite pinky, and press the ’ key with your right pinky..: the . key, with your right ring finger.+: the = key with Shift. Press Shift with the opposite pinky, and press the = key with your right pinky.
Two short examples: "Type" "fast" is one joined string, and student.name reaches the name field of a struct called student.
Technique tips
- Think about the closing quote before you type the words inside. Knowing where the text ends keeps the pair neat.
- After the period key, bring your right ring finger back to the home row so the next letter is ready.
- When you type
+, press Shift with the opposite pinky first, then reach to the = key. - Check the screen. Look for the space between two joined strings, and make sure the period sits right against the field name.
Lessons
- Lesson 1, learn (10 to 15 minutes): Watch the
",.and+symbols on the keyboard demo. Type each one five times. - Lesson 2, practice (10 to 15 minutes): Type
"Type" "fast"andstudent.name. Check that every quote pair closes. - Lesson 3, review (10 to 15 minutes): Take the two-minute test with lines that hold text and periods. Save your result and practice the symbols you missed.
This week’s goal
This week’s target is 21 WPM and 93% accuracy. Finishing the week’s lessons earns you 1 star. Reach 93% accuracy for 2 stars, and also reach 21 WPM for 3 stars. A missing quote can confuse the compiler about the lines after it, so keep your accuracy high.
Symbols this week
The colored keys are the ones you learn this week. The color shows which finger presses the key.
This week’s lessons
Do the lessons in order. Each one ends with a test, and your best result is saved.