Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 71d4404

Browse filesBrowse files
committed
Add stack code
1 parent d0da3ea commit 71d4404
Copy full SHA for 71d4404

2 files changed

+13-1Lines changed: 13 additions & 1 deletion

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎src/test/java/datastructure/stack/MyStackWithArrayListTest.java‎

Copy file name to clipboardExpand all lines: src/test/java/datastructure/stack/MyStackWithArrayListTest.java
+6Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@
99
import static org.junit.Assert.assertThat;
1010

1111
public class MyStackWithArrayListTest {
12+
13+
/*
14+
TASK
15+
ArrayList를 사용하여 Stack을 구현한다.
16+
*/
17+
1218
@Test
1319
public void test() {
1420
MyStackWithArrayList<Integer> stack = new MyStackWithArrayList<>();
Collapse file

‎src/test/java/datastructure/stack/MyStackWithArrayTest.java‎

Copy file name to clipboardExpand all lines: src/test/java/datastructure/stack/MyStackWithArrayTest.java
+7-1Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@
66
import static org.junit.Assert.assertThat;
77

88
public class MyStackWithArrayTest {
9+
10+
/*
11+
TASK
12+
Array를 사용하여 Stack을 구현한다.
13+
*/
14+
915
@Test
1016
public void test() {
1117
MyStackWithArray stack = new MyStackWithArray();
@@ -25,7 +31,7 @@ public void test() {
2531
assertThat(stack.pop(), is(2));
2632
assertThat(stack.pop(), is(1));
2733
assertThat(stack.pop(), is(0));
28-
34+
2935
// java.lang.RuntimeException: Empty Stack!
3036
// assertThat(0, is(stack.pop()));
3137
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.