text: #include <iostream>
  
  using namespace std;
  
  int main(int argc, char const *argv[]) {
      long long n, m;
      cout << "Enter matrix sizes (n x m): ";
      cin >> n >> m;
      char **matrix = new char* [n];
      for (int i = 0; i < n; ++i) {
          matrix[i] = new char[m];
      }
      cout << "Enter matrix elements" << "\n";
      for (int i = 0; i < n; ++i) {
          for (int j = 0; j < m; ++j) {
              cin >> matrix[i][j];
          }
      }
      long long str, dgt_cnt = 0, tmp = 0;
      for (int i = 0; i < n; ++i) {
          for (int j = 0; j < m; ++j) {
              if (isdigit(matrix[i][j])) {
                  tmp++;
              }
          }
          if (tmp > dgt_cnt) {
              dgt_cnt = tmp;
              str = i;
          }
      }
      cout << "First string " << str << " contains the biggest amount of digits - " << dgt_cnt << "\n";
      for (int i = 0; i < n; ++i) {
          delete [] matrix[i];
      }
      return 0;
  }
  