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

class B:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: G = None
        self.x: F = None
        self.y: G = None
        self.z: G = None
        self.o: A = None
        self.s: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: F = None
        self.o: F = None
        self.y: D = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.q: B = None
        self.v: G = None
        self.y: G = None
        self.w: C = None
        self.p: G = None
        self.u: A = None
        self.t: F = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: E = None
        self.w: B = None
        self.txt = txt

m = A("m")
i = B("i")
j = C("j")
e = D("e")
b = E("b")
l = F("l")
n = G("n")
d = F("d")
a = D("a")
g = E("g")

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

class B:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: G = None
        self.x: F = None
        self.y: G = None
        self.z: G = None
        self.o: A = None
        self.s: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: F = None
        self.o: F = None
        self.y: D = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.q: B = None
        self.v: G = None
        self.y: G = None
        self.w: C = None
        self.p: G = None
        self.u: A = None
        self.t: F = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: E = None
        self.w: B = None
        self.txt = txt

m = A("m")
i = B("i")
j = C("j")
e = D("e")
b = E("b")
l = F("l")
n = G("n")
d = F("d")
a = D("a")
g = E("g")

m.p = d
m.t = i
m.y = a
m.s = j
m.x = n
i.v = m
i.o = m
i.t = n
i.y = n
i.z = n
i.x = d
i.s = b
j.q = l
j.o = l
j.y = a
e.w = n
e.t = n
e.q = j
e.z = b
b.p = e
b.s = d
b.z = i
b.u = i
b.q = l
b.y = l
b.t = g
l.q = i
l.v = n
l.y = n
l.p = n
l.w = j
l.u = m
l.t = d
n.o = g
n.w = i
d.q = i
d.v = n
d.y = n
d.p = n
d.w = j
d.u = m
d.t = l
a.w = n
a.t = n
a.q = j
a.z = g
g.p = e
g.s = l
g.y = l
g.z = i
g.u = i
g.q = d
g.t = b
assert a.w.w.o.s.txt == "j"