print('{0:.2f}'.format((lambda x: x.count("A") / len(x))(input().split())))
F B A A B C A D
0.38
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!