#include using namespace std; int main() { int n,m,i,j,v[110][110],r = 0; char c; cin>>n>>m; for (i=1;i<=105;i++) { v[0][i] = 0; v[i][0] = 0; } for (i=1;i<=n;i++) { for (j=1;j<=m;j++) { cin>>c; if (c == '.') { if ((v[i-1][j] == 0) && (v[i][j-1] == 0)) { v[i][j] = 0; if (i == 1 && j == 1) v[i][j] = 1; } else { v[i][j] = max(v[i-1][j], v[i][j-1]) + 1; } if (r < v[i][j]) r = v[i][j]; } else v[i][j] = 0; } } cout<