(write(loop for i = (read-line t nil nil) sum (count #\* i) while i))