7 kyu
Simple Fun #62: Draw Rectangle
134 of 369myjinxin2015
Loading description...
Puzzles
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.
C# tests generate warnings:
done
python new test framework is required. updated in this fork
Already approved some time ago
The output in the example of the description is bad, no asterisk appears in it, due to bad markdown formatting ([['a', 'a', 'a', 'a', 'a', 'a', 'a', 'a'], ['a', '', '-', '-', '', 'a', 'a', 'a'], ['a', '|', 'a', 'a', '|', 'a', 'a', 'a'], ['b', '', '-', '-', '', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b']] should be [['a', 'a', 'a', 'a', 'a', 'a', 'a', 'a'], ['a', '*', '-', '-', '*', 'a', 'a', 'a'], ['a', '|', 'a', 'a', '|', 'a', 'a', 'a'], ['b', '*', '-', '-', '*', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b']].
Fixed.
haskell : https://www.codewars.com/kumite/5be897312a37b2b47c000a84?sel=5be897312a37b2b47c000a84
The when block is to check for a weird / rare edge case that your ranges in the randoms will sometimes generate ~4-5 times out of a thousand in haskell with the specifications. If you uncomment the when block you can see it.
Approved. Cheers O_o
Played with
uncomment the when block
, and see what's happening ;-)I'm trying this on ruby and can't seem to figure it out. It's rated 7 so I'm guessing I'm missing something fairly simple?
It isn't a puzzle, just do it by hand first.