class A:
    def __init__(self, txt: str):
        self.y: D = None
        self.o: D = None
        self.r: F = None
        self.t: G = None
        self.s: G = None
        self.q: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: E = None
        self.s: D = None
        self.txt = txt

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: D = None
        self.w: E = None
        self.v: E = None
        self.txt = txt

c = A("c")
j = B("j")
i = C("i")
a = D("a")
f = E("f")
d = F("d")
l = G("l")
n = D("n")
k = A("k")

c.y = a
c.o = a
c.r = d
c.t = l
c.s = l
c.q = j
j.p = f
j.s = a
i.z = j
i.t = j
a.w = k
a.y = n
a.o = d
f.y = l
d.x = n
d.y = a
l.p = n
l.z = n
l.w = f
l.v = f
n.w = c
n.y = a
n.o = d
k.y = a
k.o = a
k.r = d
k.t = l
k.s = l
k.q = j
assert i.z.p.y.w.y.txt == "
class A:
    def __init__(self, txt: str):
        self.y: D = None
        self.o: D = None
        self.r: F = None
        self.t: G = None
        self.s: G = None
        self.q: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: E = None
        self.s: D = None
        self.txt = txt

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: D = None
        self.w: E = None
        self.v: E = None
        self.txt = txt

c = A("c")
j = B("j")
i = C("i")
a = D("a")
f = E("f")
d = F("d")
l = G("l")
n = D("n")
k = A("k")

c.y = a
c.o = a
c.r = d
c.t = l
c.s = l
c.q = j
j.p = f
j.s = a
i.z = j
i.t = j
a.w = k
a.y = n
a.o = d
f.y = l
d.x = n
d.y = a
l.p = n
l.z = n
l.w = f
l.v = f
n.w = c
n.y = a
n.o = d
k.y = a
k.o = a
k.r = d
k.t = l
k.s = l
k.q = j
assert i.z.p.y.w.y.txt == "l"