in reply to Re: count repeatation
in thread count repeatation
I wrote it . I have given program above . i want to know the repeatation number without using while loop$string ='ab23cdefgXX(3A5)XXhijkl23mnXX(3)XXopq432rsXX(450b)XXtuv'; $count=0; while($string =~ m/XX/g) { $count++; } print $count;;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: count repeatation
by marto (Cardinal) on Aug 19, 2009 at 11:52 UTC | |
by saranperl (Initiate) on Aug 19, 2009 at 11:57 UTC |