![](http://i1.daumcdn.net/thumb/C148x148/?fname=https://blog.kakaocdn.net/dn/b4rGPA/btq3mqQv8BC/vkxxuEeYTiSJEv6iJzBXC1/img.png)
Codility - Distinct 중복 처리 문제Codility - Distinct 중복 처리 문제 Write a function function solution(A); that, given an array A consisting of N integers, returns the number of distinct values in array A. For example, given array A consisting of six elements such that: A[0] = 2 A[1] = 1 A[2] = 1 A[3] = 2 A[4] = 3 A[5] = 1 the function should return 3, because there are 3 distinct values appearing in array..
![](http://i1.daumcdn.net/thumb/C148x148/?fname=https://blog.kakaocdn.net/dn/We5QQ/btq3n8up9Dw/5YjYar9KhRa2tzKVEa2pk0/img.png)
Codility - PermCheck 순열 체크하는 문제 A non-empty array A consisting of N integers is given. A permutation is a sequence containing each element from 1 to N once, and only once. For example, array A such that: A[0] = 4 A[1] = 1 A[2] = 3 A[3] = 2 is a permutation, but array A such that: A[0] = 4 A[1] = 1 A[2] = 3 is not a permutation, because value 2 is missing. The goal is to check whether array A is ..