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

class B:
    def __init__(self, txt: str):
        self.y: A = None
        self.p: D = None
        self.w: F = None
        self.u: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: E = None
        self.x: F = None
        self.o: E = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.o: D = None
        self.txt = txt

n = A("n")
k = B("k")
g = C("g")
j = D("j")
l = E("l")
a = F("a")
b = C("b")
c = F("c")
i = A("i")
f = A("f")

n.s = f
n.x = f
n.o = i
n.p = g
n.v = j
n.u = l
k.y = f
k.p = j
k.w = a
k.u = b
g.s = l
g.o = l
g.x = c
j.r = c
j.o = a
j.p = l
j.v = l
l.t = g
l.v = g
l.y = f
l.w = b
l.o = a
a.r = g
a.o = j
b.s = l
b.o = l
b.x = a
c.r = b
c.o = j
i.s = n
i.o = f
i.x = f
i.p = g
i.v = j
i.u = l
f.s = n
f.o = n
f.p = g
f.x = i
f.v = j
f.u = l
assert i.u.v.s.o.o.o.r.x.txt == "
class A:
    def __init__(self, txt: str):
        self.s: A = None
        self.o: A = None
        self.p: C = None
        self.x: A = None
        self.v: D = None
        self.u: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: A = None
        self.p: D = None
        self.w: F = None
        self.u: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: E = None
        self.x: F = None
        self.o: E = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.o: D = None
        self.txt = txt

n = A("n")
k = B("k")
g = C("g")
j = D("j")
l = E("l")
a = F("a")
b = C("b")
c = F("c")
i = A("i")
f = A("f")

n.s = f
n.x = f
n.o = i
n.p = g
n.v = j
n.u = l
k.y = f
k.p = j
k.w = a
k.u = b
g.s = l
g.o = l
g.x = c
j.r = c
j.o = a
j.p = l
j.v = l
l.t = g
l.v = g
l.y = f
l.w = b
l.o = a
a.r = g
a.o = j
b.s = l
b.o = l
b.x = a
c.r = b
c.o = j
i.s = n
i.o = f
i.x = f
i.p = g
i.v = j
i.u = l
f.s = n
f.o = n
f.p = g
f.x = i
f.v = j
f.u = l
assert i.u.v.s.o.o.o.r.x.txt == "c"