You should specify which is the carry bit for the Full adder.
The truth table has the rows set up as "Cout S" while the output of the function is [S Cout]
I see, you used Regular Expression to solve that one. So if a string just so happens to start with a special character, then it would return weird results.
I seem to run into issues in the random test section, and it usually results in a 40% difference and I am unable to figure out why. I resubmitted until it passed and wrote down the ones I couldn't figure out. Then I used your solution to try and see the problem.
s1 = "^ptbA9oD*tlFWilGWLu", s2="rqrx&RSsKUciXXz?p}p"
same length: --> +10
same number of letters: --> +5
Two strings are composed of a single identical character: --> +40
Whole score = 55%
Contains the same letters:2 --> +4
Total score = 59%
That is obviously not a single identical character, but your solution reports it as such, so that may be the problem I have been having.
You should specify which is the carry bit for the Full adder.
The truth table has the rows set up as "Cout S" while the output of the function is [S Cout]
It would be better to define what you mean by midpoint of what. It took awhile before I realized that it was of a word and not of a string.
That works now
I see, you used Regular Expression to solve that one. So if a string just so happens to start with a special character, then it would return weird results.
I seem to run into issues in the random test section, and it usually results in a 40% difference and I am unable to figure out why. I resubmitted until it passed and wrote down the ones I couldn't figure out. Then I used your solution to try and see the problem.
That is obviously not a single identical character, but your solution reports it as such, so that may be the problem I have been having.
You should define what it means to be a word. Does the puncuation at the end count (which apparently it does)
Rather than returning 'Error', it would be better to throw Error('Error') in Javascript.
For the Javascript tests, you should remove the default test at the top.
Just leave your tests in.
This comment is hidden because it contains spoiler information about the solution
That is really clever. Using regular expression to parse a context-free language. Sounds like a bad idea, but the way it is set up, it works.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Yeah, that is fine.
When the number is negative, the test is asking to round up, not down.
-3000.567 rounded down is -3000.6, not -3000.5
The actual and expect values are flipped
Loading more items...