use ? instead of {0,1} for regexp