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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.v: C = None
        self.p: B = None
        self.s: A = None
        self.txt = txt

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

a.u = g
a.o = f
a.p = m
a.w = m
a.v = e
a.t = e
e.r = l
e.p = f
g.v = l
f.y = l
f.r = g
m.w = f
m.z = a
m.o = a
m.q = e
m.p = g
j.z = f
j.u = l
j.v = e
j.t = g
j.q = a
l.q = j
l.v = g
l.p = e
l.s = a
n.w = f
n.z = a
n.o = a
n.q = e
n.p = g
assert e.p.y.q.v.txt == "
class A:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: D = None
        self.p: E = None
        self.v: B = None
        self.t: B = None
        self.w: E = None
        self.txt = txt

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.v: C = None
        self.p: B = None
        self.s: A = None
        self.txt = txt

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

a.u = g
a.o = f
a.p = m
a.w = m
a.v = e
a.t = e
e.r = l
e.p = f
g.v = l
f.y = l
f.r = g
m.w = f
m.z = a
m.o = a
m.q = e
m.p = g
j.z = f
j.u = l
j.v = e
j.t = g
j.q = a
l.q = j
l.v = g
l.p = e
l.s = a
n.w = f
n.z = a
n.o = a
n.q = e
n.p = g
assert e.p.y.q.v.txt == "e"