OSDN Git Service
(root)
/
oi-wiki
/
main.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bde5728
)
'ans' should be inited to 1
author
tp
<544016459@qq.com>
Wed, 21 Aug 2019 08:14:57 +0000
(16:14 +0800)
committer
GitHub
<noreply@github.com>
Wed, 21 Aug 2019 08:14:57 +0000
(16:14 +0800)
docs/dp/index.md
patch
|
blob
|
history
diff --git
a/docs/dp/index.md
b/docs/dp/index.md
index
6ed5a4a
..
a97e71f
100644
(file)
--- a/
docs/dp/index.md
+++ b/
docs/dp/index.md
@@
-123,7
+123,7
@@
int dp() {
int a[MAXN], d[MAXN];
int dp() {
d[1] = 1;
- int ans =
0
;
+ int ans =
1
;
for (int i = 2; i <= n; i++) {
for (int j = 1; j < i; j++)
if (a[j] < a[i]) {