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

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: B = None
        self.x: A = None
        self.w: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: F = None
        self.u: F = None
        self.z: A = None
        self.p: F = None
        self.t: D = None
        self.txt = txt

a = A("a")
k = B("k")
g = C("g")
l = D("l")
c = E("c")
d = F("d")
j = C("j")
m = F("m")

a.x = j
a.t = j
a.o = g
a.u = k
a.p = l
a.s = l
k.u = c
k.w = c
k.t = j
k.q = m
k.v = d
k.z = l
g.y = a
g.p = k
g.z = d
g.v = d
g.t = l
l.p = g
c.u = k
c.x = a
c.w = j
d.w = m
d.u = m
d.p = m
d.z = a
d.t = l
j.y = a
j.p = k
j.z = m
j.v = m
j.t = l
m.w = d
m.u = d
m.p = d
m.z = a
m.t = l
assert g.y.o.t.p.t.p.txt == "
class A:
    def __init__(self, txt: str):
        self.x: C = None
        self.o: C = None
        self.u: B = None
        self.t: C = None
        self.p: D = None
        self.s: D = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: B = None
        self.x: A = None
        self.w: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: F = None
        self.u: F = None
        self.z: A = None
        self.p: F = None
        self.t: D = None
        self.txt = txt

a = A("a")
k = B("k")
g = C("g")
l = D("l")
c = E("c")
d = F("d")
j = C("j")
m = F("m")

a.x = j
a.t = j
a.o = g
a.u = k
a.p = l
a.s = l
k.u = c
k.w = c
k.t = j
k.q = m
k.v = d
k.z = l
g.y = a
g.p = k
g.z = d
g.v = d
g.t = l
l.p = g
c.u = k
c.x = a
c.w = j
d.w = m
d.u = m
d.p = m
d.z = a
d.t = l
j.y = a
j.p = k
j.z = m
j.v = m
j.t = l
m.w = d
m.u = d
m.p = d
m.z = a
m.t = l
assert g.y.o.t.p.t.p.txt == "g"