1const toCapitalCase = (string) => {
2 return string.charAt(0).toUpperCase() + string.slice(1);
3};
1var string = "A string";
2
3var upperCase = string.toUpperCase();
4console.log(upperCase); // -> A STRING
5
6var lowerCase = string.toLowerCase();
7console.log(lowerCase); // -> a string
1let dna = " TCG-TAC-gaC-TAC-CGT-CAG-ACT-TAa-CcA-GTC-cAt-AGA-GCT ";
2dna = dna.trim().toUpperCase();
3console.log(dna);
4