Calculate the Max minus Min Value in Array
1. Initialize random index for minimum and maximum value. Anyhow it's gonna be updated. 2. To find the max and min element in an array, use Max and Min function. Example Code in Java public class Main{ public static void main(String args[]) { int arr[] = {2,4,3,7,5}; System.out.println(getMinMax(arr)); } public static int getMinMax(int[] arr) { //just set arbitrary index 0,1 for now int min = ar..
Algorithms
2019. 9. 8. 14:43
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- string class in java
- easy javascript algorithm
- substring()
- math.abs
- HackerRank Algorithm
- Object type casting
- java
- algorithm
- C++
- compareTo()
- 프로그래머스 알고리즘
- spring boot application
- 프로그래머스 알고리즘문제
- hackerrank javascript solution
- ... in Javascript
- hackerrank
- math.max
- 프로그래머스
- Javascript Algorithm
- hackerrank javascript
- rest parameter
- code refactoring
- 알고리즘
- Collection Framework
- HashMap
- easy algorithm
- hackerrank solution
- repeat()
- equals()
- javascript
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
글 보관함