Unique characters

Report a typo

Write a function that takes a CharSequence as input and returns the number of unique characters in the sequence.

Sample Input 1:

abacaba

Sample Output 1:

3
Write a program in Kotlin
fun countUniqueChars(sequence: CharSequence): Int {
// write your code here
}
___

Create a free account to access the full topic