class A:
    def __init__(self, txt: str):
        self.v: E = None
        self.u: I = None
        self.x: F = None
        self.p: E = None
        self.y: D = None
        self.r: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: F = None
        self.r: C = None
        self.z: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: A = None
        self.p: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: C = None
        self.v: I = None
        self.s: I = None
        self.u: B = None
        self.y: G = None
        self.r: G = None
        self.p: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.w: G = None
        self.t: I = None
        self.q: H = None
        self.x: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: I = None
        self.o: C = None
        self.p: C = None
        self.u: I = None
        self.t: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: E = None
        self.s: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: D = None
        self.w: F = None
        self.r: C = None
        self.s: H = None
        self.txt = txt

b = A("b")
c = B("c")
e = C("e")
k = D("k")
l = E("l")
i = F("i")
m = G("m")
j = H("j")
a = I("a")

b.v = l
b.p = l
b.u = a
b.r = a
b.x = i
b.y = k
c.y = i
c.r = e
c.z = j
e.y = b
e.p = a
k.o = e
k.v = a
k.s = a
k.p = a
k.u = c
k.y = m
k.r = m
l.u = e
i.w = m
i.t = a
i.q = j
i.x = c
m.q = a
m.u = a
m.o = e
m.p = e
m.t = k
j.y = l
j.s = e
a.o = k
a.w = i
a.r = e
a.s = j
assert b.u.w.w.q.w.t.txt == "
class A:
    def __init__(self, txt: str):
        self.v: E = None
        self.u: I = None
        self.x: F = None
        self.p: E = None
        self.y: D = None
        self.r: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: F = None
        self.r: C = None
        self.z: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: A = None
        self.p: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: C = None
        self.v: I = None
        self.s: I = None
        self.u: B = None
        self.y: G = None
        self.r: G = None
        self.p: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.w: G = None
        self.t: I = None
        self.q: H = None
        self.x: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: I = None
        self.o: C = None
        self.p: C = None
        self.u: I = None
        self.t: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: E = None
        self.s: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: D = None
        self.w: F = None
        self.r: C = None
        self.s: H = None
        self.txt = txt

b = A("b")
c = B("c")
e = C("e")
k = D("k")
l = E("l")
i = F("i")
m = G("m")
j = H("j")
a = I("a")

b.v = l
b.p = l
b.u = a
b.r = a
b.x = i
b.y = k
c.y = i
c.r = e
c.z = j
e.y = b
e.p = a
k.o = e
k.v = a
k.s = a
k.p = a
k.u = c
k.y = m
k.r = m
l.u = e
i.w = m
i.t = a
i.q = j
i.x = c
m.q = a
m.u = a
m.o = e
m.p = e
m.t = k
j.y = l
j.s = e
a.o = k
a.w = i
a.r = e
a.s = j
assert b.u.w.w.q.w.t.txt == "a"