文件inorderBL.py,python中序遍历:
#!/usr/bin/env python
# coding=utf-8
# inorderBL.py
import stdinInput
def inorder(arrays,arraysize,currentP):
if(2*currentP+1<arraysize):
inorder(arrays,arraysize,2*currentP+1)
print arrays[currentP]
if(2*currentP+2<arraysize):
inorder(arrays,arraysize,2*currentP+2)
if __name__=='__main__':
stdinInput.stdinInput()
inorder(stdinInput.intsortArrays,len(stdinInput.intsortArrays),0)