On Saturday, 15 December 2012 at 12:33:13 UTC, bearophile wrote:
js.mdnq:

static if (std.string.indexOf(S, ")") < -1)
  ...
else
  ...

This always returns false regardless if S contains a 7 or not.

If it doesn't find the substring it returns -1, so that's always false. So use:

S.indexOf(")") < 0

Bye,
bearophile

OMG! duhie!!! I must be turning into a goofy goober!

Reply via email to