http://qs321.pair.com?node_id=588785


in reply to same program different output

In program I you are checking if the regular expression /[abc][hij]/ matches the string " aj", which it does.

In program II you are checking if regular expression / aj/ matches the string "[abc][hij]", which it does not.