Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import com.sun.source.util.Trees;
- import java.io.BufferedReader;
- import java.io.IOException;
- import java.io.InputStreamReader;
- import java.util.*;
- public class asf {
- public static void main(String[] args) throws IOException {
- BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
- TreeSet<String> text = new TreeSet<>();
- String string = reader.readLine();
- for (char characterOfWord : string.toCharArray())
- text.add(characterOfWord + "");
- System.out.println();
- for (String charater : text) {
- System.out.println(charater + ":");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement