Proof By Induction

Jan 21, 2015

public class WeightedQuickUnionPathCompressionUF {
private int[] id; // id[i] = parent of i
private int[] sz; // sz[i] = number of objects in subtree rooted at i
private int count; // number of components

[code]....

Show that, in each tree produced by the method of weighted quick unionwith or without path compression, the degree of the root (i.e., the number of its dependants) is not less than the height of the tree. I know that the height of a tree with 2^n nodes is n, however i dont know how to quantify the number of dependents in a way to use induction to prove that dependents>=height.

View Replies


ADVERTISEMENT

Document Comparison / Proof Reading

Feb 14, 2014

So - working on some new document composition tasks today, and realised my life would be made easier if I could have an application to allow me to compare two documents and highlight the differences...I know I could use a number of other tools, even word compare but it would be more fun if I could do it myself. Plus - there's the thrill of using non-approved technology at my workplace...I'm a maverick.

Just looking for the high level steps I should go through in creating an application which could be delivered to users in my team as an executable file (I have admin rights to my works laptop, but my direct reports do not have this on theirs) so would need to be able to run the app without installing if possible...

View Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved