7 kyu
What is type of variable?
898 of 899darlanmendonca
Loading description...
Fundamentals
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.
No random tests
Node 18 should be enabled (Refer this and this for more info)
This comment has been hidden.
You should return the type as string, not the value themself.
Consider adjusting the third example in your instructions to be
type('') => 'string'
instead oftype({}) => 'string'
so that you're not saying an object literal should produce'string'
Fixed.
CoffeeScript translation Kumited! Please Accept :D
This one is a little bit more complicated than your other Kata, which is commendable. The problem is that there is a typo in the kata description:
should be:
Fixed.
random tests needed
has some practical example?
hardly, sorry
.
Hi @darlanmendonca, you could look up the test cases of other javascript katas you have solved for examples (most will have random tests). You just need to generate random numbers/strings/etc and test the user solution against your own solution in the tests. Like this:
Where
makeRandomVariable
andmySolution
are appropriate functions defined in the tests.