-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Manacher's algorithm inconsistency #1393
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
Manacher's algorithm inconsistency #1393
Conversation
Questions to MaintainersHey! Maybe I've missed it while reading contribution docs, but is there an ability to run tests locally (especially on OS other than unix)? I've been trying to use Also, couple of questions regarding tests:
P.S. same question about providing docker container to render/display the docs locally |
Also, what about adding this problem to the list? https://leetcode.com/problems/longest-palindromic-substring/description/ |
Idk what act tool is. Are you on windows or Mac? with windows you should be able to run on WSL and on Mac you can get a more recent version of bash to run test.sh. The checks are run manually but can probably be set to run automatically. |
@jxu thanks for the info. I'm on win. For some reason, I didn't think about WSL, but rather was trying to launch the container specified in github actions locally on my machine :) |
The container approach should work too as long as you have a standard bash, python, and C++ compiler environment set up |
Hi there! You can run tests locally via bash script, as described here. I think in the long run it'd be great to somehow integrate code snippets with https://lib.cp-algorithms.com, but I'm not really sure how it can be done, if at all. As for Docker, etc, I don't think we have the capacity to develop something on our end for this. That is, if someone comes up with a solution that somehow makes our life easier, we'd be happy to discuss it over a pull request. |
#include <bits/stdc++.h> | ||
using namespace std; | ||
|
||
#include "manacher_odd.h" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you also add a test on vector<int> manacher(string s)
, please?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the pull request! If it is okay for you, could you also cover manacher
with tests? I think it should be a minimal change in the current context.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, let me merge this first to fixate the progress. But I would appreciate it if you add a test for manacher
in a separate pull request.
* Fix inconsistencies in Manacher's algorithm * Add test for manacher_odd * Update test_manacher_odd.cpp * empty commit to run tests? --------- Co-authored-by: Yurii A. <l.soho@tuta.io> Co-authored-by: Oleksandr Kulkov <adamant.pwn@gmail.com>
Changes