class A:
    def __init__(self, txt: str):
        self.v: E = None
        self.w: F = None
        self.y: B = None
        self.p: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: E = None
        self.x: H = None
        self.u: A = None
        self.q: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: A = None
        self.x: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.v: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: E = None
        self.w: H = None
        self.s: I = None
        self.r: H = None
        self.q: A = None
        self.z: H = None
        self.txt = txt

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

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

e = A("e")
g = B("g")
n = C("n")
h = D("h")
i = E("i")
l = F("l")
f = G("f")
b = H("b")
j = I("j")

e.v = i
e.p = i
e.w = l
e.y = g
g.p = i
g.x = b
g.u = e
g.q = f
n.u = e
n.x = i
h.v = j
h.y = i
i.v = j
l.q = e
l.r = e
l.t = f
f.x = i
f.w = b
f.r = b
f.z = b
f.s = j
f.q = e
b.x = h
b.w = h
b.r = i
j.v = n
assert e.w.t.q.y.u.y.txt == "
class A:
    def __init__(self, txt: str):
        self.v: E = None
        self.w: F = None
        self.y: B = None
        self.p: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: E = None
        self.x: H = None
        self.u: A = None
        self.q: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: A = None
        self.x: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.v: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: E = None
        self.w: H = None
        self.s: I = None
        self.r: H = None
        self.q: A = None
        self.z: H = None
        self.txt = txt

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

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

e = A("e")
g = B("g")
n = C("n")
h = D("h")
i = E("i")
l = F("l")
f = G("f")
b = H("b")
j = I("j")

e.v = i
e.p = i
e.w = l
e.y = g
g.p = i
g.x = b
g.u = e
g.q = f
n.u = e
n.x = i
h.v = j
h.y = i
i.v = j
l.q = e
l.r = e
l.t = f
f.x = i
f.w = b
f.r = b
f.z = b
f.s = j
f.q = e
b.x = h
b.w = h
b.r = i
j.v = n
assert e.w.t.q.y.u.y.txt == "g"