Delete a last character from a string in javascript


var a = "wxyz"; a = a.substr(0, a.length - 1); console.log(a); // wxy

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *

Show Buttons
Hide Buttons