Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cse332-18au
p1
Commits
b3dbe0b5
Commit
b3dbe0b5
authored
Jan 18, 2016
by
Adam Blank
Browse files
Cleans up patch
parent
b8386e57
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/cse332/jazzlib/HuffmanCompressor.java
View file @
b3dbe0b5
...
...
@@ -79,7 +79,6 @@ public class HuffmanCompressor
int
[]
bl_counts
;
int
minNumCodes
,
numCodes
;
int
maxLength
;
boolean
single
;
Tree
(
int
elems
,
int
minCodes
,
int
maxLength
)
{
super
(
BitString
.
class
);
...
...
@@ -272,14 +271,6 @@ public class HuffmanCompressor
Node
real
=
heap
.
next
();
heap
.
add
(
new
Node
(
null
,
real
));
}
/*
while (heap.size() < 2) {
int node = maxCode < 2 ? ++maxCode : 0;
Node n = new Node(0, node);
heap.add(n);
maxCode++;
}
*/
numCodes
=
Math
.
max
(
maxCode
+
1
,
minNumCodes
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment