#include using namespace std; int main() { string S; cin >> S; int ans = 0; for (int i = 0, j = 0; i < S.size(); i += 3) { if (S.at(i) == -30) ans = max(ans, ++j); else j = 0; } cout << ans << "\n"; }