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

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

class C:
    def __init__(self, txt: str):
        self.s: A = None
        self.t: A = None
        self.o: E = None
        self.v: J = None
        self.x: E = None
        self.p: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: I = None
        self.q: A = None
        self.z: I = None
        self.y: E = None
        self.x: G = None
        self.s: I = None
        self.v: I = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.w: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: J = None
        self.q: F = None
        self.v: E = None
        self.y: A = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.p: A = None
        self.v: C = None
        self.o: G = None
        self.u: B = None
        self.s: F = None
        self.r: B = None
        self.w: B = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.s: A = None
        self.t: A = None
        self.o: E = None
        self.v: J = None
        self.x: E = None
        self.p: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: I = None
        self.q: A = None
        self.z: I = None
        self.y: E = None
        self.x: G = None
        self.s: I = None
        self.v: I = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.w: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: J = None
        self.q: F = None
        self.v: E = None
        self.y: A = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.p: A = None
        self.v: C = None
        self.o: G = None
        self.u: B = None
        self.s: F = None
        self.r: B = None
        self.w: B = None
        self.txt = txt

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

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