0

This is my string "HelloHowAre" I want to print it like this - Hello How Are Using For loop

2
  • is this static string ??? Commented Sep 21, 2021 at 11:07
  • Help me please how i can print it one bye one using for loop Commented Sep 21, 2021 at 11:12

1 Answer 1

1

you can try with the below javascript code

var newvalll = 'HelloHowAre'.match(/[A-Z][a-z]+|[0-9]+/g);
   var res = String(newvalll);
   var nameArr = res.split(',');

for (var i = 0; i < nameArr.length; i++) {
     alert(nameArr[i]);
}

I think this is help to you

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.