# coding=UTF-8: import math import collections coordinates = str(input()) cList = collections.Counter(coordinates) cDict = dict(cList) cValue = list(cDict.values()) a, b = cValue[0], cValue[1] ans = math.sqrt(a**2 + b**2) print(ans)