import re

pattern = r'\b([A-Z]{2,4})\s(4000|[1-3][0-9]{3}):\s("[a-zA-Z]+(?:\s[a-zA-Z]+)*")'

s = ("CS 1110: \"Introduction to Programming\", ENGR 1624: \"Introduction to\n"
	"Engineering\", and BME 2220: \"Biomechanics\"\n\n"
	"CS 20: \"Introduction to CS\", ENGR 1624: \" \", and ENGR 1624: \"\"")

print(re.findall(pattern, s))