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

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

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

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.y: A = None
        self.z: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.p: D = None
        self.q: E = None
        self.v: B = None
        self.u: E = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.y: A = None
        self.z: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.p: D = None
        self.q: E = None
        self.v: B = None
        self.u: E = None
        self.txt = txt

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

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