5 kyu
Simple Finite State Machine Compiler
549 of 810awesomeaf
Loading description...
State Machines
Interpreters
Compilers
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.
Python fork with updated test framework and some other improvements (random test generation altered, needs review)
Approved
The example in the description is not very clear, it is better to write it somehow, separating the first elements like this:
S1; (S1, S2); 9
S2; (S1, S3); 10
S3; (S4, S3); 8
S4; (S4, S1); 0
('Unlocked', 0, ['Locked', 'Unlocked', 'Unlocked', 'Unlocked', 'Locked', 'Unlocked', 'Locked', 'Locked', 'Locked', 'Unlocked']) should equal ('Unlocked', 1, ['Locked', 'Unlocked', 'Unlocked', 'Unlocked', 'Locked', 'Unlocked', 'Locked', 'Locked', 'Locked', 'Unlocked']) How should output value equal 1.It should be zero.There are two test cases, I think like this which are wrong.
the tests are correct. How do you expect anyone to trust your judgment here when you don't provide the input to actually prove your point? ;)
This might help: https://docs.codewars.com/training/troubleshooting/
Cheers
Great kata .. mind twister !
Ruby 3.0 should be enabled, read this to learn how to do it
Please organize the structure of test fixture as following (although it has been mentioned in the attached link, I'm repeated here again)
Enabled in this fork
C18 should be enabled.
I'm trying to approve translations but I'm getting the following error: "Description cannot be approved, recent changes from related record must be merged first." And I can't seem to find a way around it.
not an issue, it's the... "normal" behavior. Those translatins needs to be forked to update the description (there have been some changes in the actual description since the publication of the translation, that's what's causing the problem).
Julia translation here
Ruby translation kumited, including updated description -- please check and approve :-)
Anyone?
JS translation up here
Would love it if someone smarter than me looked it over / approved :)
This comment has been hidden.
I wanted to fix the C translation and ended up rewriting most of it (including function prototypes). Take a look if you'd like to accept it as is or maybe use some parts in another fork. https://www.codewars.com/kumite/5cf949e5c84344002a3388f1
The provided C solution does not pass the unittest, although the unittest follows the code example. The provided solution seems to perform one extra state transition.
The C version reference used in the tests is incorrect which can lead to segfault. The provided C solution is just as incorrect as the used reference. It is a pity because the idea of the kata is quite nice. I got my compile to replace the solution compile, so I am pretty confident about the result.
New C translation approved.
The code blocks are messed up in the description, and some of the code blocks should be replaced with
if:language
blocks.Description updated with the C translation, but fixing the description wasn't my primary goal, so I think it might need some futher improvement.
New issues/suggestions can be raised in case the description turns out to be inadequate. As for this particular issue - I think it's looking alright now.
As @frogamic, my solution crashes and no feedback is given.
I suppose it was in C? C translation updated.
My C solution crashes in the actual test whenever I try to set the value of
*path_len
in therun_fsm
function. It works fine in the sample test, and I can assert that it is set correctly. Ispath_len
correctly passed intorun_fsm
by reference in the actual test case?C translation updated.
Approved