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

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

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

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

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.q: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: C = None
        self.s: G = None
        self.z: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.y: C = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.q: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: C = None
        self.s: G = None
        self.z: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.y: C = None
        self.txt = txt

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

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