JS Built-ins
π
en
|
es
Apprentice
0 XP
β
Search
βK
Exam β
Stats β
Learning Path
β
β°
β Home
String
0 / 195 completed (0%)
All Difficulties
Beginner
Intermediate
Advanced
All
Not Started
Attempted
Completed
Exercises (195)
β
String() β convert number to string
Beginner
β
String() β convert boolean to string
Beginner
β
String() β convert null and undefined
Beginner
β
String() vs new String() β primitive vs object
Intermediate
β
String() β convert array to string
Intermediate
β
String.fromCharCode() β single character
Beginner
β
String.fromCharCode() β build a word
Beginner
β
String.fromCharCode() β uppercase alphabet range
Beginner
β
String.fromCharCode() β special characters
Intermediate
β
String.fromCharCode() β round-trip with charCodeAt
Intermediate
β
String.fromCodePoint() β basic usage
Beginner
β
String.fromCodePoint() β emoji / supplementary planes
Intermediate
β
String.fromCodePoint() β multiple code points
Beginner
β
String.fromCodePoint() vs fromCharCode β BMP equivalence
Intermediate
β
String.fromCodePoint() β string length with emoji
Intermediate
β
String.raw β basic tagged template
Beginner
β
String.raw β backslash-n not a newline
Beginner
β
String.raw β interpolation still works
Intermediate
β
String.raw β compare with regular template literal
Intermediate
β
String.raw β unicode escape not interpreted
Intermediate
β
String.prototype.at() β positive index
Beginner
β
String.prototype.at() β negative index
Beginner
β
String.prototype.at() β second-to-last character
Beginner
β
String.prototype.at() β middle character
Intermediate
β
String.prototype.at() β out-of-bounds returns undefined
Intermediate
β
String.prototype.charAt() β first character
Beginner
β
String.prototype.charAt() β last character
Beginner
β
String.prototype.charAt() β out-of-bounds returns empty string
Beginner
β
String.prototype.charAt() β middle character
Intermediate
β
String.prototype.charAt() β specific position
Beginner
β
String.prototype.charCodeAt() β code for A
Beginner
β
String.prototype.charCodeAt() β NaN for out-of-bounds
Beginner
β
String.prototype.charCodeAt() β detect lowercase
Intermediate
β
String.prototype.charCodeAt() β code of second character
Beginner
β
String.prototype.charCodeAt() β detect digit character
Intermediate
β
String.prototype.codePointAt() β basic ASCII
Beginner
β
String.prototype.codePointAt() β emoji code point
Intermediate
β
String.prototype.codePointAt() β surrogate at position 1
Advanced
β
String.prototype.codePointAt() β undefined for out-of-bounds
Beginner
β
String.prototype.codePointAt() β vs charCodeAt for BMP
Intermediate
β
String.prototype.concat() β join two strings
Beginner
β
String.prototype.concat() β multiple strings
Beginner
β
String.prototype.concat() β coerces non-strings
Beginner
β
String.prototype.concat() β concat with empty string
Beginner
β
String.prototype.concat() β returns a new string
Intermediate
β
String.prototype.endsWith() β basic match
Beginner
β
String.prototype.endsWith() β no match
Beginner
β
String.prototype.endsWith() β case-sensitive
Beginner
β
String.prototype.endsWith() β endPosition parameter
Intermediate
β
String.prototype.endsWith() β empty string suffix
Beginner
β
String.prototype.includes() β substring found
Beginner
β
String.prototype.includes() β not found
Beginner
β
String.prototype.includes() β case-sensitive
Intermediate
β
String.prototype.includes() β with position parameter
Intermediate
β
String.prototype.includes() β empty string always returns true
Beginner
β
String.prototype.indexOf() β found returns index
Beginner
β
String.prototype.indexOf() β not found returns -1
Beginner
β
String.prototype.indexOf() β fromIndex parameter
Intermediate
β
String.prototype.indexOf() β first occurrence only
Beginner
β
String.prototype.indexOf() β empty string always at 0
Beginner
β
String.prototype.isWellFormed() β normal string is true
Intermediate
β
String.prototype.isWellFormed() β lone surrogate is false
Intermediate
β
String.prototype.isWellFormed() β emoji string is true
Beginner
β
String.prototype.isWellFormed() β empty string is true
Beginner
β
String.prototype.isWellFormed() β mixed surrogate string
Intermediate
β
String.prototype.lastIndexOf() β last occurrence
Beginner
β
String.prototype.lastIndexOf() β not found returns -1
Beginner
β
String.prototype.lastIndexOf() β fromIndex limits search
Intermediate
β
String.prototype.lastIndexOf() β multiple occurrences
Beginner
β
String.prototype.lastIndexOf() β case-sensitive
Intermediate
β
String.prototype.localeCompare() β equal strings return 0
Beginner
β
String.prototype.localeCompare() β less-than returns negative
Beginner
β
String.prototype.localeCompare() β greater-than returns positive
Beginner
β
String.prototype.localeCompare() β sort array of strings
Intermediate
β
String.prototype.localeCompare() β sign of result
Intermediate
β
String.prototype.match() β basic regex match
Intermediate
β
String.prototype.match() β global flag returns all matches
Intermediate
β
String.prototype.match() β no match returns null
Beginner
β
String.prototype.match() β capture groups
Intermediate
β
String.prototype.match() β named capture groups
Advanced
β
String.prototype.matchAll() β collect all matches
Intermediate
β
String.prototype.matchAll() β access capture groups
Intermediate
β
String.prototype.matchAll() β named capture groups
Advanced
β
String.prototype.matchAll() β empty results
Beginner
β
String.prototype.matchAll() β match index property
Intermediate
β
String.prototype.normalize() β NFC (default)
Intermediate
β
String.prototype.normalize() β NFD (decomposed)
Intermediate
β
String.prototype.normalize() β NFKC
Advanced
β
String.prototype.normalize() β NFKD
Advanced
β
String.prototype.normalize() β compare normalized strings
Intermediate
β
String.prototype.padEnd() β basic padding
Beginner
β
String.prototype.padEnd() β custom fill string
Beginner
β
String.prototype.padEnd() β no padding when already long enough
Beginner
β
String.prototype.padEnd() β fill string is truncated if needed
Intermediate
β
String.prototype.padEnd() β fixed-width table formatting
Intermediate
β
String.prototype.padStart() β zero-pad numbers
Beginner
β
String.prototype.padStart() β custom fill string
Beginner
β
String.prototype.padStart() β no padding when already long enough
Beginner
β
String.prototype.padStart() β space padding (default)
Beginner
β
String.prototype.padStart() β fixed-width number formatting
Intermediate
β
String.prototype.repeat() β basic repetition
Beginner
β
String.prototype.repeat() β zero count
Beginner
β
String.prototype.repeat() β count of 1
Beginner
β
String.prototype.repeat() β long repetition
Beginner
β
String.prototype.repeat() β empty string input
Beginner
β
String.prototype.replace() β replace first occurrence
Beginner
β
String.prototype.replace() β regex pattern
Intermediate
β
String.prototype.replace() β replace with function
Intermediate
β
String.prototype.replace() β capture groups in replacement
Intermediate
β
String.prototype.replace() β no match returns original
Beginner
β
String.prototype.replaceAll() β replace all occurrences
Beginner
β
String.prototype.replaceAll() β vs replace (only first)
Beginner
β
String.prototype.replaceAll() β regex with g flag
Intermediate
β
String.prototype.replaceAll() β empty string replacement (split-like)
Intermediate
β
String.prototype.replaceAll() β no match returns original
Beginner
β
String.prototype.search() β returns index of first match
Beginner
β
String.prototype.search() β -1 when not found
Beginner
β
String.prototype.search() β case-insensitive with /i
Intermediate
β
String.prototype.search() β vs indexOf comparison
Beginner
β
String.prototype.search() β position of digit
Beginner
β
String.prototype.slice() β basic substring
Beginner
β
String.prototype.slice() β negative start (last N chars)
Beginner
β
String.prototype.slice() β negative end
Beginner
β
String.prototype.slice() β omit end to end-of-string
Beginner
β
String.prototype.slice() β slice single char
Beginner
β
String.prototype.split() β split by character
Beginner
β
String.prototype.split() β split by string
Beginner
β
String.prototype.split() β split with limit
Intermediate
β
String.prototype.split() β empty string gives chars array
Beginner
β
String.prototype.split() β no separator returns whole string in array
Beginner
β
String.prototype.startsWith() β basic match
Beginner
β
String.prototype.startsWith() β no match
Beginner
β
String.prototype.startsWith() β case-sensitive
Beginner
β
String.prototype.startsWith() β with position param
Intermediate
β
String.prototype.startsWith() β empty string always true
Beginner
β
String.prototype.substring() β basic substring
Beginner
β
String.prototype.substring() β start === end returns empty string
Beginner
β
String.prototype.substring() β start > end swaps arguments
Intermediate
β
String.prototype.substring() β omit end goes to end of string
Beginner
β
String.prototype.substring() β extract first N chars
Beginner
β
String.prototype.toLocaleLowerCase() β basic ASCII lowercase
Beginner
β
String.prototype.toLocaleLowerCase() β mixed case
Beginner
β
String.prototype.toLocaleLowerCase() β already lowercase
Beginner
β
String.prototype.toLocaleLowerCase() β numbers and symbols unchanged
Beginner
β
String.prototype.toLocaleLowerCase() β empty string
Beginner
β
String.prototype.toLocaleUpperCase() β basic ASCII uppercase
Beginner
β
String.prototype.toLocaleUpperCase() β mixed case
Beginner
β
String.prototype.toLocaleUpperCase() β already uppercase
Beginner
β
String.prototype.toLocaleUpperCase() β numbers unchanged
Beginner
β
String.prototype.toLocaleUpperCase() β empty string
Beginner
β
String.prototype.toLowerCase() β all caps to lowercase
Beginner
β
String.prototype.toLowerCase() β mixed case to lowercase
Beginner
β
String.prototype.toLowerCase() β already lowercase unchanged
Beginner
β
String.prototype.toLowerCase() β numbers and symbols unchanged
Beginner
β
String.prototype.toLowerCase() β empty string
Beginner
β
String.prototype.toString() β primitive string
Beginner
β
String.prototype.toString() β String object vs primitive
Intermediate
β
String.prototype.toString() β returns same value as valueOf
Beginner
β
String.prototype.toString() β in template literal
Beginner
β
String.prototype.toString() β explicit call
Beginner
β
String.prototype.toUpperCase() β all lowercase to uppercase
Beginner
β
String.prototype.toUpperCase() β mixed case to uppercase
Beginner
β
String.prototype.toUpperCase() β already uppercase unchanged
Beginner
β
String.prototype.toUpperCase() β numbers and symbols unchanged
Beginner
β
String.prototype.toUpperCase() β empty string
Beginner
β
String.prototype.toWellFormed() β normal string unchanged
Intermediate
β
String.prototype.toWellFormed() β lone surrogate replaced with U+FFFD
Intermediate
β
String.prototype.toWellFormed() β string with emoji unchanged
Intermediate
β
String.prototype.toWellFormed() β empty string
Beginner
β
String.prototype.toWellFormed() β mixed lone surrogate
Intermediate
β
String.prototype.trim() β leading spaces
Beginner
β
String.prototype.trim() β trailing spaces
Beginner
β
String.prototype.trim() β both ends
Beginner
β
String.prototype.trim() β no whitespace unchanged
Beginner
β
String.prototype.trim() β tabs and newlines
Beginner
β
String.prototype.trimEnd() β trailing spaces removed
Beginner
β
String.prototype.trimEnd() β leading spaces preserved
Beginner
β
String.prototype.trimEnd() β both ends β only leading preserved
Beginner
β
String.prototype.trimEnd() β no whitespace unchanged
Beginner
β
String.prototype.trimEnd() β trailing newline
Beginner
β
String.prototype.trimStart() β leading spaces removed
Beginner
β
String.prototype.trimStart() β trailing spaces preserved
Beginner
β
String.prototype.trimStart() β both ends β only trailing preserved
Beginner
β
String.prototype.trimStart() β no whitespace unchanged
Beginner
β
String.prototype.trimStart() β leading tab
Beginner
β
String.prototype.valueOf() β returns primitive string
Beginner
β
String.prototype.valueOf() β same as toString()
Beginner
β
String.prototype.valueOf() β String object primitive value
Intermediate
β
String.prototype.valueOf() β in arithmetic context
Beginner
β
String.prototype.valueOf() β empty string valueOf
Beginner
β
String.prototype.length β basic length
Beginner
β
String.prototype.length β empty string length 0
Beginner
β
String.prototype.length β emoji length is 2 code units
Intermediate
β
String.prototype.length β spaces count toward length
Beginner
β
String.prototype.length β Unicode surrogate pairs
Advanced