liuhuan 5 vuotta sitten
vanhempi
commit
0557c11e0a
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      G.cpp

+ 2 - 2
G.cpp

@@ -6,8 +6,8 @@ using namespace std;
 const int MOD = 100000007;
 int main() {
     int F[100002][2] = {0};
-    F[1][0] = 1, F[1][1] = 1;
-    F[2][0] = 2;
+    F[1][0] = 1, F[1][1] = 1;/*将n=1单独写*/
+    F[2][0] = 2;/*进行递推*/
     F[2][1] = 1;
     int n;
     cin >> n;