i have the following:
var S="hi how are you"; var bindex = 2; var eindex = 6;
how can i remove all the chars from S that reside between bindex and eindex? therefore S will be "hi are you"
Take the text before bindex and concatenate with text after eindex, like:
var S="hi how are you"; var bindex = 2; var eindex = 6; S = S.substr(0, bindex) + S.substr(eindex);
S is now "hi are you"
2.1m questions
2.1m answers
60 comments
57.0k users