import java.io.BufferedReader;
import java.io.InputStreamReader;
class Main
{
{
String p
= bufferedReader.
readLine(); long s=0;
long[] x= {0,0,0,0,0,0,0,0,0,0};
for(int i = 0; i < p.length(); i++) {
char n = p.charAt(i);
if(n =='0') x[0]++;
else if(n =='1') x[1]++;
else if(n =='2') x[2]++;
else if(n =='3') x[3]++;
else if(n =='4') x[4]++;
else if(n =='5') x[5]++;
else if(n =='6') x[6]++;
else if(n =='7') x[7]++;
else if(n =='8') x[8]++;
else if(n =='9') x[9]++;
}
for(int i = 0; i < 10; i++)
if (x[i]>1) s+=x[i]/2;
}
}
aW1wb3J0IGphdmEuaW8uQnVmZmVyZWRSZWFkZXI7CmltcG9ydCBqYXZhLmlvLklucHV0U3RyZWFtUmVhZGVyOwoKY2xhc3MgTWFpbgp7CglwdWJsaWMgc3RhdGljIHZvaWQgbWFpbiAoU3RyaW5nW10gYXJncykgdGhyb3dzIGphdmEubGFuZy5FeGNlcHRpb24KCXsKCQlCdWZmZXJlZFJlYWRlciBidWZmZXJlZFJlYWRlciA9IG5ldyBCdWZmZXJlZFJlYWRlcihuZXcgSW5wdXRTdHJlYW1SZWFkZXIoU3lzdGVtLmluKSk7CgkJU3RyaW5nIHAgPSBidWZmZXJlZFJlYWRlci5yZWFkTGluZSgpOwoJCWxvbmcgcz0wOwoJCWxvbmdbXSB4PSB7MCwwLDAsMCwwLDAsMCwwLDAsMH07CgkJZm9yKGludCBpID0gMDsgaSA8IHAubGVuZ3RoKCk7IGkrKykgewoJCQljaGFyIG4gPSBwLmNoYXJBdChpKTsKCQkJaWYobiA9PScwJykgeFswXSsrOwoJCQllbHNlIGlmKG4gPT0nMScpIHhbMV0rKzsKCQkJZWxzZSBpZihuID09JzInKSB4WzJdKys7CgkJCWVsc2UgaWYobiA9PSczJykgeFszXSsrOwoJCQllbHNlIGlmKG4gPT0nNCcpIHhbNF0rKzsKCQkJZWxzZSBpZihuID09JzUnKSB4WzVdKys7CgkJCWVsc2UgaWYobiA9PSc2Jykge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