#include <algorithm>
#include <cstdio>
#include <bitset>

const int N = 300;
const int MOD = 998244353;

using Bitset = std::bitset<N>;

int n, m, two[N + 1];
Bitset mat[N];

int main()
{
  scanf("%d%d", &n, &m);
  for (int i = 0; i < n; ++ i) {
    for (int j = 0, a; j < m; ++ j) {
      scanf("%d", &a);
      if (a == 1) {
        mat[i].set(j);
      }
    }
  }
  int rank = 0;
  for (int j = 0; j < m; ++ j) {
    int pivot = rank;
    while (pivot < n && !mat[pivot].test(j)) {
      pivot ++;
    }
    if (pivot == n) {
      continue;
    }
    std::swap(mat[rank], mat[pivot]);
    for (int i = rank + 1; i < n; ++ i) {
      if (mat[i].test(j)) {
        mat[i] ^= mat[rank];
      }
    }
    rank ++;
  }
  two[0] = 1;
  for (int i = 1; i <= N; ++ i) {
    two[i] = two[i - 1] * 2 % MOD;
  }
  int result = 1LL * (two[n] + MOD - two[n - rank]) * two[m - 1] % MOD;
  printf("%d\n", result);
}
