
算法
袁祺
秃以言志
展开
-
线性回归
因为公式写在网上不是很方便,所以就写在纸上拍照上转了原创 2019-05-25 20:23:46 · 88 阅读 · 0 评论 -
JAVA下的栈与队列实现
栈 package 算法; import java.util.Iterator; public class stack <Item>{ private class Node{ Item item; Node next; } private Node first; private int N = 0; public boolean isEmpty() {return ...原创 2019-05-18 10:23:41 · 93 阅读 · 0 评论 -
加权并查集
union-find package unionfind; import java.io.IOException; public class UnionFind { private int[] id; private int count; public UnionFind(int N) { count = N; for(int i=0;i<N;i++) id[i] =...原创 2019-06-14 20:04:01 · 330 阅读 · 0 评论 -
深度优先搜索&&广度优先搜索
graph 队列,背包的实现在以前的记录中已实现 package 重复; public class Graph { private final int V; private int E; private bag<Integer>[] adj; public Graph(int v) { this.V = v; this.E = 0; adj = (bag<I...原创 2019-06-24 10:42:49 · 96 阅读 · 0 评论