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

class B:
    def __init__(self, txt: str):
        self.x: G = None
        self.s: H = None
        self.y: A = None
        self.q: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: G = None
        self.u: G = None
        self.s: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.t: I = None
        self.o: H = None
        self.w: G = None
        self.y: D = None
        self.u: C = None
        self.p: G = None
        self.z: E = None
        self.x: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: E = None
        self.y: D = None
        self.x: I = None
        self.p: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: C = None
        self.y: D = None
        self.x: I = None
        self.p: I = None
        self.q: D = None
        self.txt = txt

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

j = A("j")
b = B("b")
g = C("g")
c = D("c")
i = E("i")
h = F("h")
d = G("d")
n = H("n")
f = I("f")

j.y = d
j.o = i
j.x = b
j.v = h
b.x = d
b.s = n
b.y = j
b.q = g
g.v = j
c.q = d
c.u = d
c.s = g
i.v = d
i.x = c
i.y = c
h.t = f
h.o = n
h.w = d
h.p = d
h.y = c
h.u = g
h.z = i
h.x = b
d.t = i
d.p = i
d.y = c
d.x = f
n.w = g
n.y = c
n.q = c
n.x = f
n.p = f
f.w = n
f.p = n
f.q = n
f.x = c
f.s = d
f.o = d
f.r = d
f.v = b
assert f.v.x.y.txt == "
class A:
    def __init__(self, txt: str):
        self.y: G = None
        self.o: E = None
        self.x: B = None
        self.v: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: G = None
        self.s: H = None
        self.y: A = None
        self.q: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: G = None
        self.u: G = None
        self.s: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.t: I = None
        self.o: H = None
        self.w: G = None
        self.y: D = None
        self.u: C = None
        self.p: G = None
        self.z: E = None
        self.x: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: E = None
        self.y: D = None
        self.x: I = None
        self.p: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: C = None
        self.y: D = None
        self.x: I = None
        self.p: I = None
        self.q: D = None
        self.txt = txt

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

j = A("j")
b = B("b")
g = C("g")
c = D("c")
i = E("i")
h = F("h")
d = G("d")
n = H("n")
f = I("f")

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