#include <bits/stdc++.h>
using namespace std;
int main() {
  const int nn = 1000;
  int mas[nn][nn], n, m, k, row[nn], col[nn];
  scanf("%d%d%d", &n, &m, &k);
  for (int i = 0; i < nn; i++) {
    row[i] = i;
    col[i] = i;
  }
  for (int i = 0; i < n; i++)
    for (int j = 0; j < m; j++) scanf("%d", &mas[i][j]);
  for (int Count = 0; Count < k; Count++) {
    int a, b;
    char s;
    cin.get();
    scanf("%1c", &s);
    scanf("%d %d", &a, &b);
    a--;
    b--;
    if (s == 'c')
      swap(col[a], col[b]);
    else if (s == 'r')
      swap(row[a], row[b]);
    else
      printf("%d\n", mas[row[a]][col[b]]);
  }
  return 0;
}
