class A:
    def __init__(self, txt: str):
        self.u: F = None
        self.t: D = None
        self.q: B = None
        self.x: C = None
        self.s: A = None
        self.v: F = None
        self.txt = txt

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

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

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

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

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

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

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

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

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

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

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

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

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

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