#!/usr/bin/python
import sys
import os
import re

def ly2midi_links(s):
    r = re.compile("(href=\"lily-\d+\.)ly\"")
    def repl_func(m):
        return "%smidi\"" % m.groups()
    s = r.sub(repl_func, s)
    return s

s = sys.stdin.read()
s = ly2midi_links(s)
sys.stdout.write(s)
