in reply to Re: Longest possible run of a single character
in thread Longest possible run of a single character
EXTREME TIMTOWTDI :)
#!/usr/bin/perl -l # http://perlmonks.org/?node_id=551038 use strict; use warnings; $_ = 'ABDBACCBBBCBDDBCDCBCCDBABCBABBBBBADACDABACC'; print "longest run: ", length eval "'".s/(.)\K\B(?!\1)/'|'/gr."'";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Longest possible run of a single character
by Anonymous Monk on Sep 24, 2015 at 22:09 UTC |