class A:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: B = None
        self.q: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: E = None
        self.x: D = None
        self.o: E = None
        self.w: A = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.y: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: B = None
        self.q: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: E = None
        self.x: D = None
        self.o: E = None
        self.w: A = None
        self.txt = txt

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

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

g.s = e
e.y = g
j.v = e
j.q = k
c.r = a
c.x = l
c.o = b
c.w = g
b.q = e
b.p = a
b.s = a
b.t = h
h.v = e
h.q = k
a.q = e
a.p = b
a.s = b
a.t = j
k.s = e
l.r = a
l.x = c
l.o = b
l.w = g
assert h.v.y.s.y.s.y.s.y.s.txt == "e"