
java数据结构
chengyue2007
想学习java
展开
-
Java 遍历二叉树
Binary.java import java.util.Stack; public class BinaryTree {protected Node root; public BinaryTree(Node root) { this.root = root;} public Node getRoot() { return root;} /** 构造树 */public stat...原创 2009-12-21 20:06:53 · 95 阅读 · 0 评论 -
java中图的遍历
/*class Queue { private int[] values; private int begin = -1; private int end = -1; Queue(int size) { values = new int[size]; } void push(int value) {values[++begin] = value;} int pop() { return valu...2009-12-21 20:14:01 · 141 阅读 · 0 评论