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

class B:
    def __init__(self, txt: str):
        self.u: G = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.z: F = None
        self.w: B = None
        self.u: G = None
        self.x: E = None
        self.y: H = None
        self.v: G = None
        self.s: G = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.v: E = None
        self.o: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: F = None
        self.s: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: H = None
        self.u: B = None
        self.o: J = None
        self.t: G = None
        self.r: B = None
        self.w: F = None
        self.y: F = None
        self.q: H = None
        self.x: J = None
        self.s: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.t: A = None
        self.s: D = None
        self.p: D = None
        self.o: B = None
        self.q: B = None
        self.y: D = None
        self.x: A = None
        self.w: A = None
        self.z: C = None
        self.v: H = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.u: G = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.z: F = None
        self.w: B = None
        self.u: G = None
        self.x: E = None
        self.y: H = None
        self.v: G = None
        self.s: G = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.v: E = None
        self.o: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: F = None
        self.s: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: H = None
        self.u: B = None
        self.o: J = None
        self.t: G = None
        self.r: B = None
        self.w: F = None
        self.y: F = None
        self.q: H = None
        self.x: J = None
        self.s: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.t: A = None
        self.s: D = None
        self.p: D = None
        self.o: B = None
        self.q: B = None
        self.y: D = None
        self.x: A = None
        self.w: A = None
        self.z: C = None
        self.v: H = None
        self.txt = txt

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

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