last word in sentence js example
Example: inbuilt javascript functions for last word check
function test(words) {
var n = words.indexOf(" ");
var res = words.substring(n+1,-1);
return res;
}
function test(words) {
var n = words.indexOf(" ");
var res = words.substring(n+1,-1);
return res;
}