7 kyu
Training Time
443 of 3,672myjinxin2015
Loading description...
Fundamentals
Tutorials
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.
Note the words "arbitrary number" in the problem statement. They mean an infinite number of arrays consisting of two digits.
This comment has been hidden.
This was way harder than a 7 kyu imo, should be 5 or 6
Description could use some work for CoffeeScript. f.ex spreads in CS has the ellipse on the right side of the variable
I found the description of the kata to be unhelpful, so I had to seek assistance from ChatGPT to understand the author's intentions.
I think this is a bit harder than 7. Spent some good time.
that kata would be easier if there wasnt any instructions.
Node 12 should be enabled (Refer this and this for more info)
Python new test framework should be used (Refer this & this for more detail)
Ruby 3.0 should be enabled (Refer this & this for more detail)
Done for Python.
Done for Ruby
JS still needs
mocha + chai
enabledKata's starting from #22 makes me think to forget about coding.
i too feel the same in the past, just come back when you gain more knowledge in your particular language (assuming it's JS
no, too difficult for me. Had to watch and review solutions, to understand how to complete it.
I almost did not read the description, as I could not understand most of it and I felt lazy to try it. I looked at the sample tests in Python, solved it after guessing that actually we're just asked to return the array (first argument) swapping pairs of its elements which indexes are in the following arguments. Then I did the same in JS. I think description should be completely rewritten since the task is actually easy but description is completely misleading.
Confusing how? Are you talking bout the task or tutorial?
As I wrote, the task is easy but the tutorial is misleading since it has little to do with the task. Most solutions (included the author's one) don't use arrow function.
Thank you! You've saved me from reading description. Sometimes there is a too longread and confusing descriptions.
To much information to take in for 1 kata. I dont even know where to start
It's a tutorial, it's actually shorter than most online tutorials already ~~
I dont understand the condition of the task. Is there another way to describe it?
Google more about spread operators, deconstruction and etc.
Python tests check the user solution against itself.
Fixed.
Python 3 should be enabled.
The translation dosn't works with py3. If you can, please write a new translition for it. Thanks ;-)
Add
from functools import reduce
line in the complete solution, and inside the tests before the reference solution.Made the changes. Is it okay now? ;-)
The default version should be set to
3.6.0
, but at least it's available now.For some reason, version
3.4.3
is unavailable to the user, despite not throwing any exceptions, and I have no idea why -_-Task requires using "spread operator" but there's no reasonable way to use that here and none of the top solutions have it. I spent a while trying to figure out where to use it before finally "giving up" and submitting my solution that used everything else. Made the problem frustrating/unenjoyable.
The task just told you:
The words
Try to
doesn't mean forcing users to use these things. ;-)Oh my God. This was so hard and I did it without looking at the solutions!! I don't understand anything but I did it.
CoffeeScript Translation Kumited! Please Accept :D
Approved, thanks ;-)
In the description, the term "deconstruction" is mentioned. I find no reference to that term in ECMA-6. Perhaps it could be the "destructuring assignment" ECMA-6 12.14.5?
Yes, you are right. its destructuring assignment...
This comment has been hidden.
This is great! I've been needing a good introduction to some of the new ES6 stuff, and this has helped. My one concern is that the instructions are hard to read in places. If you'd like, myjinxin2015, I'd be happy to make some suggestions.
I'm not familiar with English, so I'm very much welcome your advice.
You can release any of your suggestions, I will look at tomorrow, because now I'm going to bed (my time is 1:42 AM) Good night!
I finished an edit of the instructrions...how do I get it to you?
about description? paste it here please ;-)
This comment has been hidden.
It...looks different in a comment post. If you go full screen on a comment, then it looks more like it would when training.
(And is there any way to make it collapsible? I feel bad making people scroll that much.)
Thanks for your work, but I'm no time modify it, I will do this next day.
revision done ;-) thank you~~
Translated into both Python and Ruby: be sure, in case, to approve Python translation first to avoid merge problems and let me know if anyone arises; great exercise to show similarities and differences among this languages in dealing with the same topics :)
When I approve python, system tell me:
what means is it?
Are you sure you tried to approve Python version first? Anyway, tell me if you can approve this fork :)
approved, thank you~~
@GiacomoSorbi
,Python 3 isn't available because of two
xrange
's.Thanks!
Done :)
This comment has been hidden.
I did not ask the user to use these things to solve the kata. I just design a test case that is suitable for use with these knowledge. Allow users to understand the use of these knowledge can be more simple to solve kata. Such as the uncertainty of the number of parameters, using household needs to use
...
To accept the parameters; setting the exchange of two variables value as the goal, let users understand the use of deconstruction more simple (description includes example about exchange two value of variables)This comment has been hidden.
Yes,my fault...
I always have a question that is why some people solve the kata but don't vote for it?
Who can give me an explanation or a reason?
The answer is quite simple. Instead of being able to click on the little ^ symbol on the upper left to upvote it, you have to notice that there's an ^ Up Vote thingie on the right undernreath the Train Again button that only appears after you solve the Kata. I completed over 200 Katas before spotting it. Maybe I'm rather dense but probaby not. I tried instead to click on the little ^ on the left side where it shows the up vote numerous times before however.
So UI issue - poor usability. It's clearly not just me in this case.
I often only vote the harder ones... So if i solve it in two minutes i think perhaps it's better if other users vote it... Perhaps a bad reason... I think your complete series are really work and good katas, so perhaps it's a bad habit...
To ddrouin: when a trainer solve a beta kata, two question need to click the button: How difficult do you think this kata is?(1-8kyu)-----this is the rank Is this kata ready to come out of beta?(ready/minor issues/major issues)----this is the vote am I right? To smile67: badboy you are ;-)
Yes... as usual... ;-) But i like to give four points and i think i gave you perhaps 70 * 4 =280 points last time (for your little bit harder ones)... Should be enough;-)!
But you got 130*3=390 point by solve my kata, This is a pleasant cooperation. haha~~
Haven't solved all (probably 115*3 and some exclusively), some "thinking and testing" not;-)... I know, really a good cooperation:-)... Hope no heart attack next time;-)!
Oh that vote :-) Yeah I do that one always.
Whoever those people may be (who solve kata but don't vote for it), one thing I can say for certain is, I'm definitely not one of them! :) I myself also find this behaviour of most Codewars users very irritating. If everyone would just cooperate and upvote a kata every time they complete one, the Kata approval process would be much quicker and we wouldn't have so many "dead" beta Kata :(
Yes, you are right... And normally everyone who published a kata earned some points for the work. The harder or complexer the kata, the more points (my opinion). But the easier ones often get many points a little bit later (not from the "hardcore users", but beginners;-)), so generally the system works and it's fair. For me only these 1+2=3 katas are not worth to give points, there's no idea, no work, probably only to collect points (sorry as always my personal opinion).
easy kata easier through beta (because it is easy, so more people deal with it, so it has enough rank and vote through beta); difficult kata often due to the few people to solve it, resulted in no sufficient rank and vote to the beta phase, which then leads to fewer people can access to it, this is a vicious circle. (Translation software translation, I don't know whether the correct meaning ;-)
I want to vote some of your stuff that is in beta, but I don't have the upvote option. I just unlocked the ability to choose kata difficulty. So I will do that when I come across beta content I have completed. I would also like to help some of your grammar. Would you be interested in me fixing that for you? Most of it makes sense, but might keep people from avoiding your stuff.
I welcome all the help, thank you very much ;-) The problem of grammar is my weakness, because I am not familiar with English.
great. I don't seem to have the honor to contribute in editing Katas. But I will work on getting there.