#include <bits/stdc++.h>
using namespace std;
const long double pi = acos(-1);
const long long inf = 1LL << 30;
const double eps = 1e-9;
const long long mod = 998244353;
const int N = 100100, M = 200;
long long dp[2][202][2];
int a[N];
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  if (a[n] == -1) {
    for (int x = 1; x <= M; x++) {
      dp[n & 1][x][1] = 1;
      dp[n & 1][x][0] = x;
    }
  } else {
    dp[n & 1][a[n]][1] = 1;
    for (int x = 1; x <= M; x++) {
      if (a[n] <= x) dp[n & 1][x][0] = 1;
    }
  }
  for (int x = 1; x <= M; x++) {
    dp[n & 1][x][1] += dp[n & 1][x - 1][1];
    dp[n & 1][x][1] %= mod;
    dp[n & 1][x][0] += dp[n & 1][x - 1][0];
    dp[n & 1][x][0] %= mod;
  }
  for (int i = n - 1; i > 1; i--) {
    int j = 1 - (i & 1);
    for (int lst = 1; lst <= M; lst++)
      dp[i & 1][lst][0] = dp[i & 1][lst][1] = 0;
    for (int lst = 1; lst <= M; lst++) {
      if (a[i] == -1) {
        dp[i & 1][lst][1] += (dp[j][lst][0] - dp[j][lst - 1][0] + mod) % mod;
        dp[i & 1][lst][1] += (dp[j][M][1] - dp[j][lst][1] + mod) % mod;
        dp[i & 1][lst][1] %= mod;
        dp[i & 1][lst][0] += dp[j][lst][0];
        dp[i & 1][lst][0] += (dp[j][M][1] - dp[j][lst][1] + mod) % mod;
        dp[i & 1][lst][0] %= mod;
      } else {
        bool f = a[i] > lst;
        if (a[i] >= lst)
          dp[i & 1][lst][1] +=
              (dp[j][a[i]][f] - dp[j][a[i] - 1][f] + mod) % mod;
        dp[i & 1][lst][0] += (dp[j][a[i]][f] - dp[j][a[i] - 1][f] + mod) % mod;
        dp[i & 1][lst][1] %= mod;
        dp[i & 1][lst][0] %= mod;
      }
    }
    for (int x = 1; x <= M; x++) {
      dp[i & 1][x][1] += dp[i & 1][x - 1][1];
      dp[i & 1][x][1] %= mod;
      dp[i & 1][x][0] += dp[i & 1][x - 1][0];
      dp[i & 1][x][0] %= mod;
    }
  }
  long long ans = 0;
  if (a[1] == -1)
    ans = dp[0][M][1];
  else
    ans = (dp[0][a[1]][1] - dp[0][a[1] - 1][1] + mod) % mod;
  ans %= mod;
  printf("%d", ans);
}
