Hi, I want to iterate through comma separated string, want to get each element but in vein, what I've in my comma separated string is as below, and how i'm trying to get is also mentioned,
Result I'm getting is on each iteration is like, it alerts each digit like 0 then 9 then 3 then decimal point (.) and so on.
I want to get 093.33 on first iteration , 789.23 on 2nd iteration and so on...
I want to get 093.33 on first iteration , 789.23 on 2nd iteration and so on...
- var CommaStr = "093.33, 789.23, 003,21, 123.43, 188.02";
- for (var j = 0; i < CommaStr .split(',').length; j++) {
- alert(CommaStr[j]);
- }


Amit MohantyRank #112 · 20K reputationPosted Dec 17, 2019, 11:36 PM EST
"));
Jignesh KumarRank #91 · 22.9K reputationPosted Dec 18, 2019, 5:07 PM EST
Rameez JavedRank #3,873 · 383 reputationPosted Dec 18, 2019, 12:41 AM EST