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

class B:
    def __init__(self, txt: str):
        self.p: A = None
        self.s: B = None
        self.y: F = None
        self.z: D = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.w: F = None
        self.x: D = None
        self.v: A = None
        self.z: A = None
        self.y: F = None
        self.t: A = None
        self.txt = txt

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

m = A("m")
b = B("b")
g = C("g")
a = D("a")
i = E("i")
l = F("l")
k = B("k")
h = E("h")
f = F("f")

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

class B:
    def __init__(self, txt: str):
        self.p: A = None
        self.s: B = None
        self.y: F = None
        self.z: D = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.w: F = None
        self.x: D = None
        self.v: A = None
        self.z: A = None
        self.y: F = None
        self.t: A = None
        self.txt = txt

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

m = A("m")
b = B("b")
g = C("g")
a = D("a")
i = E("i")
l = F("l")
k = B("k")
h = E("h")
f = F("f")

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