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

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

class C:
    def __init__(self, txt: str):
        self.o: D = None
        self.r: A = None
        self.w: G = None
        self.u: F = None
        self.q: G = None
        self.t: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: G = None
        self.p: A = None
        self.v: G = None
        self.s: D = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.z: J = None
        self.r: F = None
        self.w: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.t: F = None
        self.u: G = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.o: D = None
        self.r: A = None
        self.w: G = None
        self.u: F = None
        self.q: G = None
        self.t: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: G = None
        self.p: A = None
        self.v: G = None
        self.s: D = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.z: J = None
        self.r: F = None
        self.w: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.t: F = None
        self.u: G = None
        self.txt = txt

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

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