in reply to Re: Print the string out in alternating upper and lowercase letters LiKe tHiS.
in thread Print the string out in alternating upper and lowercase letters LiKe tHiS.
Of course, at this point we should perhaps consider ucfirst and fc...perl -CO -Mutf8 -E 'say map { /\P{Cased}/ ? $_ : $c++ % 2 ? lc : uc } "comme ça" =~ /(\X)/g'
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Print the string out in alternating upper and lowercase letters LiKe tHiS.
by Anonymous Monk on Jan 26, 2015 at 14:22 UTC |