Help in JavaScript | SoloLearn: Learn to code for FREE!

0

Help in JavaScript

I want a for loop that this process will repeat for more than one numbers https://code.sololearn.com/Wz8zWbmdS2h1/?ref=app

4/13/2021 5:23:37 PM

Hrithik Mishra

1 Answer

New Answer

+2

here is your solution var string = ["+919999999999","+918888888888","+917777777777"]; for (i in string){ string[i] = string[i].slice(-10); } document.write(string)