in reply to matching white spaces in perl
Or if you only want one single blank,
m/ ?<result>
See perlretut for an introduction to regular expressions.
Update: as SuicideJunkie++ pointed out, the leading \s* or ? are pretty pointless unless you either anchor the regex or look at the match variables after the match.
|
|---|