class A:
    def __init__(self, txt: str):
        self.w: B = None
        self.o: D = None
        self.q: C = None
        self.z: C = None
        self.txt = txt

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

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

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

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

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

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

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

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

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

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

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

e.w = g
e.o = j
e.q = a
e.z = a
g.p = a
g.y = i
g.s = i
a.p = i
a.o = i
i.x = j
l.z = c
l.r = c
d.w = g
d.o = i
d.q = a
d.z = a
h.w = g
h.o = i
h.q = a
h.z = a
b.z = e
b.r = c
j.x = i
c.w = g
c.o = j
c.q = a
c.z = a
assert g.s.x.x.x.x.x.x.x.txt == "j"