#include #include #include #include #include #include #define all(x) x.begin(),x.end() #define pb push_back #define ll long long #define P pair #define LP pair using namespace std; int main() { int n,m,ma=0; cin >>n>>m; vector a(m); for (int i = 0; i < n; i++) { string s; cin >> s; for (int j = 0; j < m; j++) { if (s[j] == 'x') a[j] += 1; ma = max(ma, a[j]); } } cout << ma+1 << endl; return 0; }