Skip to content

Commit d04b461

Browse files
committed
modify code
1 parent 3387eaa commit d04b461

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/class03/Code03_DoubleEndsQueueToStackAndQueue.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ public static void main(String[] args) {
162162
}
163163
}
164164
int numq = (int) (Math.random() * value);
165-
if (stack.isEmpty()) {
165+
if (queue.isEmpty()) {
166166
myQueue.push(numq);
167167
queue.offer(numq);
168168
} else {

0 commit comments

Comments
 (0)