6 kyu
Moves in squared strings (IV)
67 of 1,593g964
Loading description...
Algorithms
Strings
View
This comment has been reported as {{ abuseKindText }}.
Show
This comment has been hidden. You can view it now .
This comment can not be viewed.
- |
- Reply
- Edit
- View Solution
- Expand 1 Reply Expand {{ comments?.length }} replies
- Collapse
- Spoiler
- Remove
- Remove comment & replies
- Report
{{ fetchSolutionsError }}
-
-
Your rendered github-flavored markdown will appear here.
-
Label this discussion...
-
No Label
Keep the comment unlabeled if none of the below applies.
-
Issue
Use the issue label when reporting problems with the kata.
Be sure to explain the problem clearly and include the steps to reproduce. -
Suggestion
Use the suggestion label if you have feedback on how this kata can be improved.
-
Question
Use the question label if you have questions and/or need help solving the kata.
Don't forget to mention the language you're using, and mark as having spoiler if you include your solution.
-
No Label
- Cancel
Commenting is not allowed on this discussion
You cannot view this solution
There is no solution to show
Please sign in or sign up to leave a comment.
This is the easiest one if you did the other parts.
This was a great warmup on spinning and flipping a matrix. Going to look at the other katas you've created because these 4 "Squared strings" were fun. Thank you!
In prolog, attempting to load
clpfd
causes full tests to always timeout.Fork with fix
Approved
python new test framework is required. updated in this fork
Approved
I completed to this kata series. I enjoyed while I solved to this kata series. Thank you g964.
Thanks!
I believe a better name would be antidiagonal:
https://en.wikipedia.org/wiki/Main_diagonal#Antidiagonal
You can pass Prolog tests with the exact same code from part 3.
It clearly seems I made a confusion between part 3 and part 4. I will fix that. Very sorry!
I re-edited as it should have been. Hopefully there are no new errors. Please tell me if it is conform to the description of "Moves in squared strings (IV)" and thanks for your post. monadius passed the kata but said nothing:-(
That was quick :P Seems good now.
It was written since long...
Why is the function named diag2_sym in many other languages, but in Prolog it's diag1_sym ? :P
And it expects diag1_sym functionality too... Would you like to fix this, or should I re-raise this as an issue for now?
See above... I suppose I made a mix in my files! Sorry again!
It should have been the secondary diagonal.
Maybe my answer will not satisfy you because I don't really understand your problem all the more that many people solved the kata (218 in JS with very very good solver) and nobody complained (not a proof I know):-) The "main cross diagonal" (function noted "diag_2_sym" to recall it is a symetry to the second diagonal) is also called (from wikipedia) "antidiagonal (sometimes counter diagonal, secondary diagonal, trailing diagonal, minor diagonal, off diagonal...". Is there something wrong and where?
No answer so I consider the issue as resolved. Cheers.
I meant that the axis of symmetry is not the axis from the top left to bottom right, but rather from the top right to bottom left. (aka. axis of symmetry is antidiagonal)
if you already done Moves in squared strings (III) this kata is pretty easy
Some test-cases for the julia translation might be broken:
I need to catch calls to
diag_2_symSE
androt_90_counterSE
by hand and replace them with my own non-SE functions inoper
, otherwise some tests throw anin those two functions.
OK; I fixed two typos. Your solution now works without the need to replace by hand in your code. Can you give it a try? Thanks!
It does indeed work now. Many thanks.
Issue with Julia translation:
(At the time of writing this issue there is not any completions .)
fixed
I have reduced the tests. Please tell me if that works.
Yeah, all fixed. Thanks.
Random tests are missing in Rust.
(I haven't checked every other language version, there might be some more)
Repetition is a great tool. I've already forgotten how to use higher level functions but this kata have reminded me how it works. Thanks g964.
Thanks for your post!
Objective-C Translation Kumited - please carefully review and approve :D
great!!
Excellent series of katas, it makes you think how to compose next functions in terms of previous ones. The problem (group actions on strings) was very interesting as well!
Thanks!
interesting training, I like:)
The last one and the best one of the series. Nice training. I enjoyed all parts of the series. Thanks ;)
Thanks, it's kind of you!
After submitting I have these issues in console:
../home/codewarrior/spec.ts(1,1): error TS1084: Invalid 'reference' directive syntax. ../home/codewarrior/spec.ts(2,1): error TS1084: Invalid 'reference' directive syntax.
May be some of the reference tags in the test cases are not self-closed?
Always same problems with TS. You write without mistakes but CW saves badly! I corrected it once more but I have lots of timing-out. I'll tell you when I succeed! You can see: https://github.com/Codewars/codewars.com/issues/593
Fixed at last. Could you see if it works now?