class A:
    def __init__(self, txt: str):
        self.v: F = None
        self.w: H = None
        self.p: C = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.y: J = None
        self.r: G = None
        self.u: E = None
        self.s: J = None
        self.p: J = None
        self.v: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.z: A = None
        self.o: I = None
        self.s: I = None
        self.t: C = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.r: C = None
        self.z: G = None
        self.x: D = None
        self.s: E = None
        self.txt = txt

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

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

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.y: J = None
        self.r: G = None
        self.u: E = None
        self.s: J = None
        self.p: J = None
        self.v: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.z: A = None
        self.o: I = None
        self.s: I = None
        self.t: C = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.r: C = None
        self.z: G = None
        self.x: D = None
        self.s: E = None
        self.txt = txt

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

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

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