* reduce code

* add function overriding
* update test
This commit is contained in:
shellhub
2020-08-10 16:52:06 +08:00
parent 4be90d8afa
commit 6079b4bc10
4 changed files with 31 additions and 7 deletions

View File

@ -5,7 +5,7 @@ public class FindMax {
//Driver
public static void main(String[] args) {
int[] array = {2, 4, 9, 7, 19, 94, 5};
System.out.println("max = " + findMax(array));
assert findMax(array) == 94;
}
/**