Problem 61117. First Unique Character
Given a character vector s, return the first character that appears exactly once in s.
If every character repeats at least once, return the empty char '' (1×0 char).
Solution Stats
Problem Comments
-
1 Comment
Christian Schröder
on 8 Dec 2025 at 18:31
In addition to the broken test suite, '' is 0×0, not 1×0 (so the problem description is wrong), and it's generally better to test whether an array is empty by using isempty() rather than by explicitly comparing to e.g. ''.
Solution Comments
Show commentsProblem Recent Solvers1
Suggested Problems
-
1 Solvers
More from this Author4
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!