[TASK]:
You will be given lines of pseudocode, your task is to write the corresponding C++ code. The pseudocode will provide detailed description of the c++ code line by line. The pseudocode is garanteed to be correct and complete.

[INSTRUCTION]:
The following libraries are already included in the code.
```cpp
#include <cstdio>
#include <iostream>
#include <vector>
#include <algorithm>
#include <numeric>
#include <cmath>
#include <cstring>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <list>
#include <fstream>
#include <climits>
#include <cassert>
#include <iomanip>
#include <sstream>
#include <bitset>
using namespace std;
```
Do not include them in your code again. Please surround your code with ```cpp and ``` markers. Note that the code should correspond to the pseudocode line by line.

[PSEUDOCODE]:
create long long mod with mod = 998244353
create integer array a with size 100000
define the main function
    create integer n
    read n
    for i = 0 to n exclusive, read a[i]
    create long long vectors up, notup, prev_up, prev_notup, with up initialized with 201, notup initialized with 201, prev_up initialized with (201,0), prev_notup initialized with (201,0)
    set prev_up[0] to 1
    for i = 0 to n exclusive
        for j = 1 to 200 inclusive
            increment prev_up[j] by prev_up[j - 1], set prev_up[j] to prev_up[j] % mod
            increment prev_notup[j] by prev_notup[j-1], set prev_notup[j] to prev_notup[j] % mod
        end of the block
        set up[0] to notup[0] to 0
        for j = 1 to 200 inclusive
            set up[j] to notup[j] to 0
            if a[i] is not -1 and a[i] is not j, break current loop iteration
            increment up[j] by prev_up[j - 1] + prev_notup[j - 1], set up[j] to up[j] % mod
            increment notup[j] by prev_up[j] + prev_notup[j], set notup[j] to notup[j] % mod
            decrement notup[j] by prev_up[j - 1] + prev_notup[j - 1], set notup[j] to notup[j] % mod
            increment notup[j] by prev_notup[200] - prev_notup[j], set notup[j] to notup[j] % mod
        end of the block
        set prev_up to up
        set prev_notup to notup
    end of the block
    create long long ans with ans = 0
    for i = 1 to 200 inclusive, increment ans by prev_notup[i], set ans to ans % mod
    print ( ans + mod ) % mod print newline
end of the block

[CODE]:

long long mod = 998244353;
int a[100000];
int main() {
    int n;
    cin >> n;
    for (int i = 0; i < n; i++) cin >> a[i];
    vector<long long> up(201), notup(201), prev_up(201, 0), prev_notup(201, 0);
    prev_up[0] = 1;
    for (int i = 0; i < n; i++) {
        for (int j = 1; j <= 200; j++) {
            (prev_up[j] += prev_up[j - 1]) %= mod;
            (prev_notup[j] += prev_notup[j - 1]) %= mod;
        }
        up[0] = notup[0] = 0;
        for (int j = 1; j <= 200; j++) {
            up[j] = notup[j] = 0;
            if (a[i] != -1 && a[i] != j) continue;
            (up[j] += prev_up[j - 1] + prev_notup[j - 1]) %= mod;
            (notup[j] += prev_up[j] + prev_notup[j]) %= mod;
            (notup[j] -= prev_up[j - 1] + prev_notup[j - 1]) %= mod;
            (notup[j] += prev_notup[200] - prev_notup[j]) %= mod;
        }
        prev_up = up;
        prev_notup = notup;
    }
    long long ans = 0;
    for (int i = 1; i <= 200; i++) (ans += prev_notup[i]) %= mod;
    cout << (ans + mod) % mod << endl;
}