in reply to Find the common initial substring (prefix if you insist)

For regexps abusers, with the added condition of no null character in parameter strings:

 sub cis { (join( "\0", @_) =~ m/^([^\0]*)[^\0]*(\0\1[^\0]*)*$/)[0] } Thanks to ChemBoy for pointing an omission and compacting into one statement.

-- stefp