79805803

Date: 2025-10-31 12:52:48
Score: 5
Natty:
Report link

DOH!

I got so fixated on solving it through Regex I completely ignored the simple solution of using trim(). It does indeed work perfectly.

Many thanks for pointing out the obvious!

Do I at least get a wry smile for including references to 3rd Rock from the Sun and The Simpsons?

Reasons:
  • Blacklisted phrase (0.5): thanks
  • Low length (0.5):
  • No code block (0.5):
  • Ends in question mark (2):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Doug Antill