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

class B:
    def __init__(self, txt: str):
        self.z: A = None
        self.q: F = None
        self.x: F = None
        self.t: E = None
        self.v: E = None
        self.p: A = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.q: A = None
        self.r: C = None
        self.t: E = None
        self.o: E = None
        self.z: E = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.z: A = None
        self.q: F = None
        self.x: F = None
        self.t: E = None
        self.v: E = None
        self.p: A = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.q: A = None
        self.r: C = None
        self.t: E = None
        self.o: E = None
        self.z: E = None
        self.txt = txt

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

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

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