capitalizeFirst method
Capitalizes only the first letter of the string.
Implementation
String capitalizeFirst() {
if (isEmpty) return this;
return this[0].toUpperCase() + substring(1);
}
Capitalizes only the first letter of the string.
String capitalizeFirst() {
if (isEmpty) return this;
return this[0].toUpperCase() + substring(1);
}