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

class B:
    def __init__(self, txt: str):
        self.q: D = None
        self.p: E = None
        self.v: A = None
        self.r: F = None
        self.o: D = None
        self.z: G = None
        self.s: A = None
        self.txt = txt

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.t: B = None
        self.o: A = None
        self.p: D = None
        self.z: D = None
        self.txt = txt

n = A("n")
m = B("m")
e = C("e")
h = D("h")
l = E("l")
j = F("j")
b = G("b")
c = B("c")
a = B("a")
f = D("f")

n.t = b
m.q = f
m.p = l
m.v = n
m.s = n
m.r = j
m.o = h
m.z = b
e.s = l
e.t = l
e.p = b
e.u = b
e.o = n
e.v = j
h.w = e
h.t = l
h.x = j
l.x = h
j.p = n
b.s = e
b.t = m
b.o = n
b.p = h
b.z = f
c.q = f
c.p = l
c.v = n
c.s = n
c.r = j
c.o = h
c.z = b
a.q = f
a.o = f
a.p = l
a.v = n
a.s = n
a.r = j
a.z = b
f.w = e
f.t = l
f.x = j
assert l.x.x.p.t.z.t.x.w.txt == "
class A:
    def __init__(self, txt: str):
        self.t: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.q: D = None
        self.p: E = None
        self.v: A = None
        self.r: F = None
        self.o: D = None
        self.z: G = None
        self.s: A = None
        self.txt = txt

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.t: B = None
        self.o: A = None
        self.p: D = None
        self.z: D = None
        self.txt = txt

n = A("n")
m = B("m")
e = C("e")
h = D("h")
l = E("l")
j = F("j")
b = G("b")
c = B("c")
a = B("a")
f = D("f")

n.t = b
m.q = f
m.p = l
m.v = n
m.s = n
m.r = j
m.o = h
m.z = b
e.s = l
e.t = l
e.p = b
e.u = b
e.o = n
e.v = j
h.w = e
h.t = l
h.x = j
l.x = h
j.p = n
b.s = e
b.t = m
b.o = n
b.p = h
b.z = f
c.q = f
c.p = l
c.v = n
c.s = n
c.r = j
c.o = h
c.z = b
a.q = f
a.o = f
a.p = l
a.v = n
a.s = n
a.r = j
a.z = b
f.w = e
f.t = l
f.x = j
assert l.x.x.p.t.z.t.x.w.txt == "e"