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

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

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

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

class E:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: D = None
        self.t: D = None
        self.p: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.u: G = None
        self.y: F = None
        self.txt = txt

l = A("l")
e = B("e")
m = C("m")
j = D("j")
h = E("h")
b = F("b")
g = G("g")
c = H("c")
f = D("f")

l.o = c
l.t = c
l.y = e
l.w = b
l.q = f
l.u = m
e.w = f
e.q = m
e.r = c
m.p = b
m.x = l
m.u = g
j.q = h
j.w = h
j.t = m
j.u = e
j.s = e
j.v = f
j.r = l
j.o = l
h.x = c
b.x = j
b.t = j
b.p = h
g.v = h
g.w = j
g.y = b
c.u = g
c.y = b
f.q = h
f.w = h
f.t = m
f.u = e
f.s = e
f.v = j
f.r = l
f.o = l
assert j.r.q.r.txt == "
class A:
    def __init__(self, txt: str):
        self.o: H = None
        self.y: B = None
        self.w: F = None
        self.q: D = None
        self.t: H = None
        self.u: C = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: D = None
        self.t: D = None
        self.p: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.u: G = None
        self.y: F = None
        self.txt = txt

l = A("l")
e = B("e")
m = C("m")
j = D("j")
h = E("h")
b = F("b")
g = G("g")
c = H("c")
f = D("f")

l.o = c
l.t = c
l.y = e
l.w = b
l.q = f
l.u = m
e.w = f
e.q = m
e.r = c
m.p = b
m.x = l
m.u = g
j.q = h
j.w = h
j.t = m
j.u = e
j.s = e
j.v = f
j.r = l
j.o = l
h.x = c
b.x = j
b.t = j
b.p = h
g.v = h
g.w = j
g.y = b
c.u = g
c.y = b
f.q = h
f.w = h
f.t = m
f.u = e
f.s = e
f.v = j
f.r = l
f.o = l
assert j.r.q.r.txt == "l"