distinct

A collection of 1 post

Distinct

Problem Write a function 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: the function should return 3, because there are 3 distinct values appearing in array A, namely 1, 2 and…