First you have to determine the rate as mentioned in the question. In the given example, the rate is 2. Therefore, since "Dot – is 1 time unit long.", with rate = 2, Dot becomes 2 units long. (11 instead of 1). Same for "Dash – is 3 time units long.", it becomes 6 units long, i.e. 111111. So 111111 represent a dash and so on...
I have struggled with this kata 2 days for now and I can't understand where I am wrong.
I can't understand this thing:
we have: 110011001100110000001100000011111111.... let me split this in Morse code
11 = .
00 = nothing
11 = .
.
.
.
and so on..
but when I reach the first set of "111111"
I can't understand what is supposed to be coded in Morse as something else than : "-.." because we have the first 1 that lets us know that the line is connected, the next 3 of 1 indicate the "-" and the next 2 of 1 indicate 2 points: ...
In the converted text there is another sequention that is "-.--"
I am really glad for your help
First you have to determine the rate as mentioned in the question. In the given example, the rate is 2. Therefore, since "Dot – is 1 time unit long.", with rate = 2, Dot becomes 2 units long. (11 instead of 1). Same for "Dash – is 3 time units long.", it becomes 6 units long, i.e. 111111. So 111111 represent a dash and so on...
Hi guys,
I have struggled with this kata 2 days for now and I can't understand where I am wrong.
I can't understand this thing:
we have: 110011001100110000001100000011111111.... let me split this in Morse code
11 = .
00 = nothing
11 = .
.
.
.
and so on..
but when I reach the first set of "111111"
I can't understand what is supposed to be coded in Morse as something else than : "-.." because we have the first 1 that lets us know that the line is connected, the next 3 of 1 indicate the "-" and the next 2 of 1 indicate 2 points: ...
In the converted text there is another sequention that is "-.--"
I am really glad for your help
Thanks,
:)