8.3 KiB
a bonary tree¶
#*********************************************************************** #** a bo-binary tree * #** for and inspired by Wang Xiaobo (1952-1997), writer and programmer.* #** "我也自做了词组功能,是棵B树,我觉得自写的软件自用,感觉是最好的。" * #** "I created a word feature with a binary tree strucutre, * #** and I feel best about using a program you created yourself." * #** read more in archival documentation(Chinese): * #** https://blog.csdn.net/weixin_33697898/article/details/93356187 * #** * #***********************************************************************
思维的乐趣¶
on discourse¶
quotes from 《我的精神家园》¶
谈到思想的乐趣,我就想到我父亲的遭遇。我父亲是一位哲学教授,在五六十年代从事思维史的研究。在老年时,他告诉我自己一生的学术经历,就如一部恐怖电影。每当他企图立论时,总要在大一统的思想体系里找到自己的位置,就如一只老母鸡要在一个大搬家的宅院里找地方孵蛋一样。结果他虽然热爱科学而且很努力,在一生中却没有得到思维的乐趣,之收获了无数的恐慌。他一生的探索,只剩下了一些断壁残垣,收到一本名为《逻辑探索》的书里,在他身后出版。
我在沉默中过了很多年:插队、当工人、当大学生,后来又在大学里任过教。当教师的人保持沉默似不可能,但我教的是技术性的课程,在讲台上只讲技术性的话,下了课我就走人。找我看,不管干什么都可以保持沉默。当然,我还有一个终身爱好,就是写小说。但是写好了不拿去发表,同样也保持了沉默。至于沉默的理由,很是简单。那就是信不过话语圈。从我短短的人生经历看,它是一座声名狼藉的疯人院。当时我怀疑的不是说过亩产三十万斤粮、炸过精神原子弹的那个话语圈,而是一切话语圈子。
还有一些人,因为种种原因,对于话语的世界有某种厌恶之情。我属于这最后一种。作为最后一种人,也有义务谈自己的所见所闻。
王小波(1997).《我的精神家园》.北京:文化艺术出版社.
#Create a proof of concept dictionary tree that looks for hong(3) fu(2)
from anytree import Node, RenderTree h = Node("h") o = Node("o", parent=h) n = Node("n", parent=o) g = Node("g", parent=n)
#print node print(h) print(g) #print tree for pre, fill, node in RenderTree(h): print("%s%s" %(pre,node.name))
Node('/h') Node('/h/o/n/g') h └── o └── n └── g
f = Node("f") u = Node("u", parent = f) for pre, fill, node in RenderTree(f): print("%s%s" %(pre,node.name))
f └── u
y = Node("y") e = Node("e", parent = y) for pre, fill, node in RenderTree(y): print("%s%s" %(pre,node.name))
y └── e
b = Node("b") e = Node("e", parent = b) n = Node("n", parent = e) for pre, fill, node in RenderTree(b): print("%s%s" %(pre,node.name))
b └── e └── n
def printTree(root): for pre, fill, node in RenderTree(root): print("%s%s" %(pre,node.name))
tree_list = [h,f,y,b] 红拂夜奔 = ["红","拂","夜","奔"] counter = 0 for tree in tree_list: printTree(tree) print(红拂夜奔[counter]) counter = counter + 1 print()
h └── o └── n └── g 红 f └── u 拂 y └── e 夜 b └── e └── n 奔
# an alphabet binary search tree import string alphabet_s = string.ascii_lowercase alphabet_l = list(alphabet_s) #print(alphabet_l) # add nodes manually, starting from m
import IPython.display Video('vid/wang_interview.mp4')
# transcription of wang's interview in Chinese # autotranslate that into English for non-Chinese readers
数据结构是思维的形状的一种表现方式 the structure of data may be one representation of the form of thought
Wang Xiaobo (1952-1997), writer and programmer.
"我也自做了词组功能,是棵B树,我觉得自写的软件自用,感觉是最好的。"
"I created a word feature with a binary tree strucutre, and I feel best about using a program you created yourself."
read more in archival documentation(Chinese):
https://blog.csdn.net/weixin_33697898/article/details/93356187