class A:
    def __init__(self, txt: str):
        self.o: F = None
        self.u: F = None
        self.x: B = None
        self.p: D = None
        self.t: H = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: G = None
        self.y: B = None
        self.u: A = None
        self.q: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: C = None
        self.s: A = None
        self.z: H = None
        self.w: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.u: C = None
        self.z: D = None
        self.x: A = None
        self.w: E = None
        self.s: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.y: B = None
        self.q: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: D = None
        self.x: F = None
        self.q: B = None
        self.y: B = None
        self.v: F = None
        self.txt = txt

l = A("l")
a = B("a")
j = C("j")
n = D("n")
m = E("m")
c = F("c")
f = G("f")
i = H("i")
e = E("e")

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

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

class C:
    def __init__(self, txt: str):
        self.v: G = None
        self.y: B = None
        self.u: A = None
        self.q: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: C = None
        self.s: A = None
        self.z: H = None
        self.w: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.u: C = None
        self.z: D = None
        self.x: A = None
        self.w: E = None
        self.s: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.y: B = None
        self.q: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: D = None
        self.x: F = None
        self.q: B = None
        self.y: B = None
        self.v: F = None
        self.txt = txt

l = A("l")
a = B("a")
j = C("j")
n = D("n")
m = E("m")
c = F("c")
f = G("f")
i = H("i")
e = E("e")

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