class A:
    def __init__(self, txt: str):
        self.p: G = None
        self.o: H = None
        self.z: C = None
        self.q: E = None
        self.t: J = None
        self.u: G = None
        self.y: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.w: A = None
        self.x: F = None
        self.p: G = None
        self.y: F = None
        self.v: E = None
        self.t: G = None
        self.q: F = None
        self.txt = txt

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

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

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

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

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

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

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

e = A("e")
i = B("i")
f = C("f")
m = D("m")
b = E("b")
j = F("j")
h = G("h")
c = H("c")
k = I("k")
g = J("g")

e.p = h
e.u = h
e.y = h
e.o = c
e.z = f
e.q = b
e.t = g
i.q = f
i.s = f
i.y = c
i.p = c
i.t = k
i.v = m
i.x = e
i.o = h
f.o = j
f.x = j
f.y = j
f.q = j
f.w = e
f.p = h
f.t = h
f.v = b
m.v = b
m.z = g
m.w = i
m.r = k
m.x = j
b.v = g
b.r = e
j.q = m
j.u = b
h.x = i
h.p = f
h.u = c
c.z = h
c.t = g
c.r = b
k.t = b
g.u = c
g.t = e
assert i.t.t.v.u.t.txt == "
class A:
    def __init__(self, txt: str):
        self.p: G = None
        self.o: H = None
        self.z: C = None
        self.q: E = None
        self.t: J = None
        self.u: G = None
        self.y: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.w: A = None
        self.x: F = None
        self.p: G = None
        self.y: F = None
        self.v: E = None
        self.t: G = None
        self.q: F = None
        self.txt = txt

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

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

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

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

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

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

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

e = A("e")
i = B("i")
f = C("f")
m = D("m")
b = E("b")
j = F("j")
h = G("h")
c = H("c")
k = I("k")
g = J("g")

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