class A:
    def __init__(self, txt: str):
        self.s: B = None
        self.w: C = None
        self.q: B = None
        self.r: B = None
        self.y: D = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.z: C = None
        self.y: F = None
        self.u: B = None
        self.r: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.x: B = None
        self.s: C = None
        self.q: A = None
        self.p: D = None
        self.w: D = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.z: C = None
        self.y: F = None
        self.u: B = None
        self.r: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.x: B = None
        self.s: C = None
        self.q: A = None
        self.p: D = None
        self.w: D = None
        self.txt = txt

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

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