class A:
    def __init__(self, txt: str):
        self.t: D = None
        self.r: E = None
        self.s: C = None
        self.v: B = None
        self.y: B = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.r: C = None
        self.s: A = None
        self.v: E = None
        self.t: E = None
        self.q: A = None
        self.txt = txt

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

i = A("i")
k = B("k")
j = C("j")
l = D("l")
f = E("f")
b = E("b")
c = C("c")
g = D("g")

i.t = g
i.r = b
i.s = j
i.v = k
i.y = k
k.q = i
j.v = k
j.r = b
j.p = g
j.y = l
l.r = j
l.s = i
l.q = i
l.v = b
l.t = b
f.s = b
f.q = l
f.t = k
f.r = i
b.s = f
b.q = g
b.t = k
b.r = i
c.v = k
c.r = f
c.p = g
c.y = l
g.r = j
g.s = i
g.q = i
g.v = f
g.t = f
assert b.r.s.y.t.s.r.s.txt == "
class A:
    def __init__(self, txt: str):
        self.t: D = None
        self.r: E = None
        self.s: C = None
        self.v: B = None
        self.y: B = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.r: C = None
        self.s: A = None
        self.v: E = None
        self.t: E = None
        self.q: A = None
        self.txt = txt

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

i = A("i")
k = B("k")
j = C("j")
l = D("l")
f = E("f")
b = E("b")
c = C("c")
g = D("g")

i.t = g
i.r = b
i.s = j
i.v = k
i.y = k
k.q = i
j.v = k
j.r = b
j.p = g
j.y = l
l.r = j
l.s = i
l.q = i
l.v = b
l.t = b
f.s = b
f.q = l
f.t = k
f.r = i
b.s = f
b.q = g
b.t = k
b.r = i
c.v = k
c.r = f
c.p = g
c.y = l
g.r = j
g.s = i
g.q = i
g.v = f
g.t = f
assert b.r.s.y.t.s.r.s.txt == "j"