class A:
    def __init__(self, txt: str):
        self.o: E = None
        self.q: D = None
        self.u: H = None
        self.r: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: H = None
        self.x: A = None
        self.q: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.y: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.x: F = None
        self.z: B = None
        self.s: B = None
        self.q: C = None
        self.p: G = None
        self.r: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: D = None
        self.s: C = None
        self.u: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: C = None
        self.x: G = None
        self.t: G = None
        self.u: E = None
        self.w: B = None
        self.s: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: H = None
        self.y: E = None
        self.o: F = None
        self.z: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: E = None
        self.p: A = None
        self.o: D = None
        self.y: D = None
        self.txt = txt

e = A("e")
l = B("l")
i = C("i")
d = D("d")
g = E("g")
k = F("k")
m = G("m")
h = H("h")
b = F("b")
f = E("f")

e.o = f
e.q = d
e.u = h
e.r = h
l.t = h
l.q = h
l.x = e
i.v = e
i.y = k
d.o = m
d.p = m
d.x = b
d.z = l
d.s = l
d.q = i
d.r = f
g.o = d
g.s = i
g.u = h
k.y = i
k.x = m
k.t = m
k.s = m
k.u = g
k.w = l
m.w = h
m.y = g
m.o = k
m.z = d
h.w = f
h.p = e
h.o = d
h.y = d
b.y = i
b.x = m
b.t = m
b.s = m
b.u = g
b.w = l
f.o = d
f.s = i
f.u = h
assert f.u.w.o.r.u.y.r.s.txt == "
class A:
    def __init__(self, txt: str):
        self.o: E = None
        self.q: D = None
        self.u: H = None
        self.r: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: H = None
        self.x: A = None
        self.q: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.y: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.x: F = None
        self.z: B = None
        self.s: B = None
        self.q: C = None
        self.p: G = None
        self.r: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: D = None
        self.s: C = None
        self.u: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: C = None
        self.x: G = None
        self.t: G = None
        self.u: E = None
        self.w: B = None
        self.s: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: H = None
        self.y: E = None
        self.o: F = None
        self.z: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: E = None
        self.p: A = None
        self.o: D = None
        self.y: D = None
        self.txt = txt

e = A("e")
l = B("l")
i = C("i")
d = D("d")
g = E("g")
k = F("k")
m = G("m")
h = H("h")
b = F("b")
f = E("f")

e.o = f
e.q = d
e.u = h
e.r = h
l.t = h
l.q = h
l.x = e
i.v = e
i.y = k
d.o = m
d.p = m
d.x = b
d.z = l
d.s = l
d.q = i
d.r = f
g.o = d
g.s = i
g.u = h
k.y = i
k.x = m
k.t = m
k.s = m
k.u = g
k.w = l
m.w = h
m.y = g
m.o = k
m.z = d
h.w = f
h.p = e
h.o = d
h.y = d
b.y = i
b.x = m
b.t = m
b.s = m
b.u = g
b.w = l
f.o = d
f.s = i
f.u = h
assert f.u.w.o.r.u.y.r.s.txt == "i"