/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package datatahti2016.pkg1;
import java.util.*;
/**
*
* @author alexey
*/
public class Datatahti20161 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
IO io = new IO();
String input=io.next();
int answer=0;
answer+=input.length();
int[] letters=new int[26];
for (int i = 0; i < input.length(); i++) {
int c =input.charAt(i)-65;
letters[c]++;
}
for (int i = 0; i < input.length(); i++) {
if(letters[i]==0){
}else{
answer+=letters[i]-1;
}
}
io.println(answer);
io.close();
}
}