import re, sys, io, urllib.request, ssl
sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8')
ctx = ssl.create_default_context(); ctx.check_hostname=False; ctx.verify_mode=ssl.CERT_NONE
def get(url):
    req = urllib.request.Request(url, headers={"User-Agent":"Mozilla/5.0"})
    with urllib.request.urlopen(req, timeout=12, context=ctx) as resp:
        return resp.read().decode("utf-8","ignore")
body=get("https://graduateschool.nd.edu/admissions/")
links=re.findall(r'href="([^"]+)"', body)
for l in dict.fromkeys(links):
    if any(k in l.lower() for k in ["tuition","fee","cost","bursar","financial","aid","fund"]):
        print("LINK", l)
txt=re.sub(r'<script[\s\S]*?</script>','',body); txt=re.sub(r'<style[\s\S]*?</style>','',txt)
txt=re.sub(r'<[^>]+>',' ',txt); txt=re.sub(r'\s+',' ',txt)
for m in re.finditer(r'[^.]*\$[\d,]+[^.]*\.?', txt):
    print("  $:", m.group(0).strip()[:120])
