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

class B:
    def __init__(self, txt: str):
        self.q: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: D = None
        self.v: D = None
        self.o: C = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: D = None
        self.s: C = None
        self.o: C = None
        self.p: A = None
        self.t: A = None
        self.u: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: E = None
        self.r: E = None
        self.t: C = None
        self.y: E = None
        self.u: A = None
        self.v: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: F = None
        self.q: C = None
        self.w: D = None
        self.u: C = None
        self.txt = txt

h = A("h")
n = B("n")
a = C("a")
d = D("d")
j = E("j")
f = F("f")
c = D("c")
b = F("b")
e = C("e")
m = E("m")

h.t = f
h.u = a
n.q = d
a.r = d
a.v = d
a.o = e
d.r = c
d.s = e
d.o = a
d.p = h
d.t = h
d.u = n
j.o = m
j.r = m
j.y = m
j.t = a
j.u = h
j.v = f
f.t = b
f.q = e
f.u = e
f.w = d
c.r = d
c.s = e
c.o = e
c.p = h
c.t = h
c.u = n
b.t = f
b.q = e
b.w = d
b.u = a
e.r = c
e.v = c
e.o = a
m.o = j
m.r = j
m.y = j
m.t = e
m.u = h
m.v = b
assert e.o.o.o.txt == "
class A:
    def __init__(self, txt: str):
        self.t: F = None
        self.u: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.q: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: D = None
        self.v: D = None
        self.o: C = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: D = None
        self.s: C = None
        self.o: C = None
        self.p: A = None
        self.t: A = None
        self.u: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: E = None
        self.r: E = None
        self.t: C = None
        self.y: E = None
        self.u: A = None
        self.v: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: F = None
        self.q: C = None
        self.w: D = None
        self.u: C = None
        self.txt = txt

h = A("h")
n = B("n")
a = C("a")
d = D("d")
j = E("j")
f = F("f")
c = D("c")
b = F("b")
e = C("e")
m = E("m")

h.t = f
h.u = a
n.q = d
a.r = d
a.v = d
a.o = e
d.r = c
d.s = e
d.o = a
d.p = h
d.t = h
d.u = n
j.o = m
j.r = m
j.y = m
j.t = a
j.u = h
j.v = f
f.t = b
f.q = e
f.u = e
f.w = d
c.r = d
c.s = e
c.o = e
c.p = h
c.t = h
c.u = n
b.t = f
b.q = e
b.w = d
b.u = a
e.r = c
e.v = c
e.o = a
m.o = j
m.r = j
m.y = j
m.t = e
m.u = h
m.v = b
assert e.o.o.o.txt == "a"