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

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.t: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: A = None
        self.q: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: C = None
        self.z: F = None
        self.v: E = None
        self.w: D = None
        self.t: B = None
        self.o: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.z: F = None
        self.r: B = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.t: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: A = None
        self.q: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: C = None
        self.z: F = None
        self.v: E = None
        self.w: D = None
        self.t: B = None
        self.o: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.z: F = None
        self.r: B = None
        self.txt = txt

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

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