Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fptree_test.cpp 错误 #20

Closed
ctlchild opened this issue May 7, 2019 · 2 comments
Closed

fptree_test.cpp 错误 #20

ctlchild opened this issue May 7, 2019 · 2 comments

Comments

@ctlchild
Copy link

ctlchild commented May 7, 2019

for (int i = 1; i <= LEAF_DEGREE; i+=2) {
EXPECT_EQ(tree->find(i), i * 100);
EXPECT_EQ(tree->update(i, i * 200), true);
}

这里只修改 key 为 1 3 5 7 等奇数 key 的 value 为 key×200,偶数 key 2 4 6 等仍然为 key×100
但是:
for (int i = 1; i <= LEAF_DEGREE; i++) {
EXPECT_EQ(tree->find(i), i * 200);
}

这里的检查却检查所有 key 的 value 是不是 key×200

因此 fp_tree_test.cpp 这里有误

@ctlchild ctlchild changed the title fp_tree.cpp 错误 fptree_test.cpp 错误 May 7, 2019
@ZhangJiaQiao
Copy link
Owner

的确有问题,好像删多了东西,待会更新

@ZhangJiaQiao
Copy link
Owner

已修正

@ctlchild ctlchild closed this as completed May 8, 2019
@ZhangJiaQiao ZhangJiaQiao pinned this issue May 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants