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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.o: A = None
        self.x: E = None
        self.u: B = None
        self.w: A = None
        self.z: E = None
        self.q: C = None
        self.txt = txt

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

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.o: A = None
        self.x: E = None
        self.u: B = None
        self.w: A = None
        self.z: E = None
        self.q: C = None
        self.txt = txt

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

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