ChinaUnix.net
相关文章推荐:

树的遍历

SYBASE怎么实现遍历 类似ORACLE的START WITH CONNECT BY PRIOR

by zq5143 - Sybase - 2009-02-25 16:26:13 阅读(2214) 回复(4)

相关讨论

.................f .............../ \ .............d....e ............/ \ ...........a...c .................\ ..................b 后序遍历线索顺序是a b c d e f,a线索b,b线索c,c如何前进到d?

by 菜鸟飞呀飞 - C/C++ - 2005-01-19 10:49:06 阅读(3448) 回复(8)

在oracle中存在tree的数据类型,偶想请教:oracle的pl/sql是否有相应的遍历的函数?如果有,在oci中是否提供与之对应的函数?

by jasonwang - Oracle - 2003-07-10 09:52:46 阅读(825) 回复(3)

就是那种有一个孩子,一个兄弟的 struct node { elementtype elem; stuct node *child; stuct node *brother; }; 要用来计算文件大小, 画了个图,不知道怎么传 谢谢

by 我是害虫 - C/C++ - 2007-11-22 20:16:58 阅读(1899) 回复(5)

有没有遍历的例子,请高手发一个

by myuid - PHP - 2004-09-15 13:25:48 阅读(958) 回复(3)

工作中遇到的一个问题,我想了一下,大概有了思路,欢迎讨论,晚上把demo代码给贴出来. 比如一个这样定义的结点. struct Node { struct Node *pLeft, *pRight, *pParent; int nKey; }; [ 本帖最后由 converse 于 2007-11-1 16:00 编辑 ]

by converse - C/C++ - 2007-11-30 18:06:57 阅读(11346) 回复(59)

#!/usr/bin/awk -F #向空中插入1000个随机数,然后遍历这棵。 BEGIN { n = 1000;root = null = -1 for(i = 1;i <= n;i++) root = insert(root,int(n*rand())) traverse(root) exit } function insert(p,x) { if(p == null) { val[p = (++nodecount)] = x lson[p] = rson[p] = null } else if(x < val[p]) { lson[p] = insert(lson[p],x) } else if(x > val[p]) { rson[p] = insert(rson[p],x) } # els...

by bianjiang007 - Shell - 2009-09-25 15:58:55 阅读(940) 回复(3)

想生成一个漂亮的型目录, 比如: -folder1 ---file11 ---file12 -folder2 ---file21 ---file22 ---folder21 ------file211 尝试着用下面这个, 略过"."或"..", 输出一般文件(&&以前)和目录(&&以后), ls -l -F |grep -v \/ | awk '/^-/ {print}' && ls -l -F |grep \/ |awk '/^d/ {print}' # 能同时输出整行的同时, 再获得最后一列的文件/目录名? 执行结果,没有递归下去 -- 加了 R 结果一下子就乱了. 还试了'find -type...

by a_mug - Shell - 2005-03-10 16:11:44 阅读(1081) 回复(5)

#!/bin/bash rmcache() { for file in 'find *' do if [-d $file] then cd $file rmcache() fi if [-f $file] then cd .. for file1 in 'find *' do rm -rf $file1 sleep 60 done sleep 60 fi done } rmcache 一个目录,在它下面有非常多的随机生成的目录,在这些随机生成目录下面还是随机生成的目录....... 这些随机目录一共6层或7层,只有在最后一层的随机目录中有文件...

by chinajordan - Shell - 2004-06-04 09:08:02 阅读(1057) 回复(6)

struts标签中的遍历 id是逻辑对象,代表name的对象。type是对象所属的类型。name是在Action中封装的对象字符串。 ${allClass.className} ${allClass.classMaster} ${allClass.isElite} ${allClass.browsePurview} 添加子栏目|修改设置|移动栏目|清空|删除 jstl中的遍历: items在Action中封装的对象字符串。var逻辑对象 ${user.id} ...

by guoguanzhao - Java文档中心 - 2006-12-15 18:03:30 阅读(403) 回复(0)

如何编写一个shell程序实现对一个目录遍历,或者在WIN的环境下写一个批处理文件完成对一个目录遍历? 谢谢!

by lianxizhong - Shell - 2004-03-10 00:42:18 阅读(2883) 回复(18)