#C12771. Unique Characters Verification
Unique Characters Verification
Unique Characters Verification
Given a string S, determine if every character in S is unique. That is, no character appears more than once in the string. For instance, the string orange
is composed of unique characters, whereas apple
contains duplicate characters.
You are required to check whether all characters in the string are distinct. Formally, for a string \( S \) of length \( n \), the condition to satisfy is: $$ n = \left| \{ s_i : s_i \in S \} \right|, $$ where \( \{ s_i : s_i \in S \} \) denotes the set of characters in S.
The comparison is case-sensitive, meaning that uppercase and lowercase letters are considered distinct.
inputFormat
The input consists of a single line containing the string S
. The string may include letters, digits, symbols, or even be empty.
outputFormat
Output a single line: True
if the string contains only unique characters, and False
otherwise.
orange
True