7 kyu
Mobile operator detector
529 of 1,223veitsi
Loading description...
Logic
Strings
Regular Expressions
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.
"one distinct country" in description is Ukraine
python new test framework is required. updated in this fork
Approved
Ruby 3.0 should be enabled.
Enabled in this fork
This is inconsistent across the languages (this is not tested in the original language, but it was written together with the original language).
This requirement doesn't explain what should be returned (so is it
"MTS Test"
or"MTS"
after all?), and looks like Giacomo is too lazy to clean up the mess he's made with his terrible translations...Changed to
MTS
according to original author's solution and other online sources [1] [2] [3]Python and Ruby: the number of tests is so small some inputs may not be generated at all.
Python version expects
"MTS"
for numbers starting with099
.Description amended.
Ruby version expects
"MTS"
for numbers starting with099
.Description amended.
Python 3 should be made available.
done.
python:
sample and fixed tests show inputs as integers but random tests send strings. that needs to be corrected one way or the other, but to use integers seems the consistent thing to do, according to the current state of the description.
same problem for ruby, and the description or the tests need to be corrected about the last identifier too.
The original uses integers, though.
Fixed, all strings (some prefixes start with a
0
).Deleted.
@Giacomo: if the orignal language uses integers, why did you convert inputs to strings? Please correct that to integers.
Tags should include regex.
Added.
This is not a regex task.
Neither is finding numbers divisible by X, but there are regex solutions. The purpose of kata's is to train in language features, not just implement the BP / most sensible approaches.
The presence of
regex
tag means that using regular expressions is a part of a task, and not a possible approach.The absence of a tag(s) is not an issue.
Kata without proper search tags is an issue, because it is one of the big problems on CW, an inability to filter kata by interest.
In regards to tags are mandatory solutions, that is almost never the case, and considering the global search tags, that could not even possibly be policy considering the named/existing tags.
JavaScript version needs random test cases
Python tests are failing:
The key
099
should return"MTS Test"
according to the description.This is the same for Ruby. Description needs fixing for 099 to either be MTS; or MTS Test and fix test.
The operator is still
"MTS"
and I took the JS version as a template; description updated.In ruby
099
should equal to"MTS Test"
according to description and not"MTS"
, description is not clear .099 xxx xx xx - MTS Test
When I set 099 equal to "MTS Test" it says that it should be MTS instead. I'm not sure if the word Test should be removed from that line in the instructions or if I just misunderstand something, but when I change it to MTS instead of MTS Test it works just fine.
Duplicate issue.
Python issue: tests expect
"Goldem Telecom"
instead of"Golden Telecom"
. Also, the description needs to be rewritten, the operators should be formatted better and separated properly.Typo fixed, description reformatted :)
Nice work. The only suggestion I have is to group the prefixes with the same operators together, but that is not neccessary.
This could need a re-write.
Agreed -- at the very least the formatting of the different operators should be improved. The block paragraph is hard to read and error-prone.
Typo fixed, description reformatted :)
number always looks like 8yyyxxxxxxx
Technically speaking, "8" isn't a part of a number, is it?Python and Ruby translations submitted, if you want to approve them; let me know if you might also appreciate random test cases in the JS version, I would strongly recommend them, and thanks for the kata :)!
Can you fix the issues given by the Python community just above? Thanks.
please, correct your translations. See above.