Chart of string methods
Chart of string methods
Table 8.15.1: Character methods return values. Each method must prepend
Character., as in Character.isLetter.
isLetter('x') // toUpperCase('a'
true // A
true if isLetter('6') // toUpperCase('A'
Uppercase
sLetter(c) alphabetic: false toUpperCase(c) // A
version
a-z or A-Z isLetter('!') // toUpperCase('3'
false // 3
toLowerCase('A'
isDigit('x') // // a
true if digit: false Lowercase toLowerCase('a'
sDigit(c) isDigit('6') // toLowerCase(c) // a
0-9. version
true toLowerCase('3'
// 3
isWhitespace(' ')
// true
true if isWhitespace('\n')
sWhitespace(c) // true
whitespace.
isWhitespace('x')
// false
https://learn.zybooks.com/zybook/2025SpringA-X-CSE110-13743_2/chapter/8/section/15 1/1