mirror of
https://github.com/TheAlgorithms/Java.git
synced 2025-07-08 10:15:51 +08:00
Add test case for CatalanNumber (#3698)
This commit is contained in:
@ -0,0 +1,14 @@
|
||||
package com.thealgorithms.dynamicprogramming;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.*;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class CatalanNumberTest {
|
||||
|
||||
@Test
|
||||
public void testCatalanNumber() {
|
||||
assertEquals(42, CatalanNumber.findNthCatalan(5));
|
||||
assertEquals(16796, CatalanNumber.findNthCatalan(10));
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user