Capitalizes the first character of a string.
The input string to capitalize.
The input string with its first character converted to uppercase.
cap("hello"); // "Hello"cap("world"); // "World" Copy
cap("hello"); // "Hello"cap("world"); // "World"
Capitalizes the first character of a string.