finir le sprint 3
This commit is contained in:
@@ -167,36 +167,6 @@ public class HuffmanTree {
|
||||
generateCodesRec(node.getLeft(), prefiixe + "0");
|
||||
// On va a droite en ajoutant "1" au code
|
||||
generateCodesRec(node.getRight(), prefiixe + "1");
|
||||
|
||||
|
||||
// this.codes = new HashMap<>();
|
||||
// this.chaineCarac = new String();
|
||||
|
||||
// if(root.isLeaf()){
|
||||
// codes.put(root.getValue(),Integer.parseInt(chaineCarac));
|
||||
// return codes;
|
||||
// }
|
||||
|
||||
// HuffmanNode temp = root;
|
||||
|
||||
// if (root.getLeft() != null) {
|
||||
// root = root.getLeft();
|
||||
// chaineCarac = chaineCarac + "0";
|
||||
// generateCodes();
|
||||
// // on retire le dernier bit lorsqu'on remonte car sinon les codes seront faussés
|
||||
// chaineCarac = chaineCarac.substring(0, chaineCarac.length() - 1);
|
||||
// }
|
||||
|
||||
// if (temp.getRight() != null) {
|
||||
// root = temp.getRight();
|
||||
// chaineCarac = chaineCarac + "1";
|
||||
// generateCodes();
|
||||
// chaineCarac = chaineCarac.substring(0, chaineCarac.length() - 1);
|
||||
// }
|
||||
|
||||
|
||||
// root = temp;
|
||||
// return codes;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user