![JavaScript basic: Create a new string from a given string changing the position of first and last characters - w3resource JavaScript basic: Create a new string from a given string changing the position of first and last characters - w3resource](https://www.w3resource.com/w3r_images/javascript-basic-image-exercise-23.png)
JavaScript basic: Create a new string from a given string changing the position of first and last characters - w3resource
![JavaScript basic: Create a new string from a given string, removing the first and last characters of the string if the first or last character are 'P' - w3resource JavaScript basic: Create a new string from a given string, removing the first and last characters of the string if the first or last character are 'P' - w3resource](https://www.w3resource.com/w3r_images/javascript-basic-image-exercise-67.png)
JavaScript basic: Create a new string from a given string, removing the first and last characters of the string if the first or last character are 'P' - w3resource
![javascript - Splitting a string by newline character succeeds but removes the last character from the string - Stack Overflow javascript - Splitting a string by newline character succeeds but removes the last character from the string - Stack Overflow](https://i.stack.imgur.com/HiWM8.jpg)