CJCoding With Joseph
15free / daySign inCreate account

The Substring method lets you pull out a smaller piece of a string. When you call Substring(startIndex, length), it returns the characters that begin at startIndex and continue for length characters. Positions are counted starting at 0. You are given a string named word set to "keyboard". Print just its first three characters by starting at index 0 and taking a length of 3.

Expected output

key

= newline. The output ends with a newline, so print one after the last line.

Hints2 available
Topics
Strings
1
Tab to indent (Esc then Tab to move on) · Ctrl+Enter to run · Shift+Alt+F to format · Ctrl+Space to expand shortcuts (cw, cr, fori)

Your output

Run your code to see the output here...

Test cases

Run your code to see test case results.