DISCHAR
All submissions for this problem are available.<h3> Read problems statements in Mandarin Chinese and Russian.</h3>
You have initially a string of N characters, denoted by A1,A2...AN. You have to print the size of the largest subsequence of string A such that all the characters in that subsequence are distinct ie. no two characters in that subsequence should be same.
A subsequence of string A is a sequence that can be derived from A by deleting some elements and without changing the order of the remaining elements.
First line contains T, number of testcases. Each testcase consists of a single string in one line. Each character of the string will be a small alphabet(ie. 'a' to 'z').
For each testcase, print the required answer in one line.
Input: 2 abc aba Output: 3 2
For first testcase, the whole string is a subsequence which has all distinct characters.
In second testcase, the we can delete last or first 'a' to get the required subsequence.