# -*- coding: utf-8 -*-
import io, sys, os, re, html
sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding="utf-8")
os.chdir(r"D:\work buddy\2026-11-05-14-15-52")
raw=open("_18_enggrad.txt","rb").read().decode("utf-8","ignore")
raw=html.unescape(re.sub(r"<script.*?</script>","",raw,flags=re.S)); raw=html.unescape(re.sub(r"<style.*?</style>","",raw,flags=re.S))
t=re.sub(r"<[^>]+>"," ",raw); t=html.unescape(re.sub(r"\s+"," ",t))
for kw in ["Fall 2027 Ph.D. and M.S.","Master of Engineering","30 credit hours","1–2 years","Spring admission","application fee","No application fee","STEM","in-person","Online"]:
    for m in re.finditer(re.escape(kw),t):
        s=max(0,m.start()-120); e=min(len(t),m.end()+260)
        print(f"\n[{kw}] {t[s:e]}")
        break
