^ - match start of line (nothing can come before it)
[1-9] - match a numeric digit from 1-9 (you could also use \d but that would allow a 0)
{1,2} - require one or two digit number
(.5)? - the group () of text .5, and ? is zero or one occurances
$- match end of string (nothing can come after it)

Yeah I just tested this on regexlib tester and it seems to only allow valid patterns.