class A:
    def __init__(self, txt: str):
        self.t: D = None
        self.x: B = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: F = None
        self.v: B = None
        self.t: B = None
        self.z: E = None
        self.s: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.t: B = None
        self.s: C = None
        self.q: A = None
        self.x: A = None
        self.r: F = None
        self.w: E = None
        self.txt = txt

h = A("h")
j = B("j")
d = C("d")
b = D("b")
c = E("c")
m = F("m")
g = F("g")
k = F("k")
i = D("i")
f = B("f")

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

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

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

class D:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: F = None
        self.v: B = None
        self.t: B = None
        self.z: E = None
        self.s: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.t: B = None
        self.s: C = None
        self.q: A = None
        self.x: A = None
        self.r: F = None
        self.w: E = None
        self.txt = txt

h = A("h")
j = B("j")
d = C("d")
b = D("b")
c = E("c")
m = F("m")
g = F("g")
k = F("k")
i = D("i")
f = B("f")

h.t = b
h.x = f
j.y = f
j.v = f
d.p = c
d.t = c
d.w = h
d.r = f
b.u = d
b.o = g
b.v = j
b.t = f
b.z = c
b.s = c
c.p = d
m.t = f
m.s = d
m.q = h
m.x = h
m.r = k
m.w = c
g.t = f
g.s = d
g.q = h
g.x = h
g.r = k
g.w = c
k.t = j
k.s = d
k.q = h
k.x = h
k.r = g
k.w = c
i.u = d
i.o = m
i.v = f
i.t = f
i.z = c
i.s = c
f.y = j
f.v = j
assert i.u.p.p.txt == "d"