+ 15
[DAILY CHALLENGES py preferred] 14 JUL 2017
🚀 CHALLENGE OF THE DAY 2/1 The spy world has changed 🕶 A shift towards the obvious has been considered As the main coder of #$@^ spy agency 🔎 ,you've been comisionned to develop a coder-decoder dealing with natural language 🏮 meet 12pm -> might output he told the boy to dig at 4 places you are free to choose to encode-decode : short messages or cipher<-> coded natural language the aim is to generate and decode quite unsuspicious pieces of text. make your rules and have fun 👌
22 Respostas
+ 13
Here's a JS solution.
https://code.sololearn.com/WZH5A0mURtpW/?ref=app
+ 11
@Abdur : Edited.
+ 8
Here is some Python:
with open("file_name.txt") as file:
for line in file:
print(" ".join(line.split()[1:]), end="")
https://code.sololearn.com/cKH7Z0VhL9y4
+ 8
Nice codes all!
Aston is my favourite
+ 5
🚤🚤🚤🚤🚤🚤🚤🚤🚤🚤🚤🚤
If you want to follow this thread
just click on the top left star.
no need to comment except to
get hints and post codes
thank you
note : implementations in other
languages welcomed. just drop
the link here
👍🤜
re-thank you
these challenges will be changed
daily
🚤🚤🚤🚤🚤🚤🚤🚤🚤🚤🚤🚤
+ 5
So, a message like "Hide the plans in the clock" could be encoded to become "Don't forget to buy dog food"?
+ 4
[continued]
after passing through your script
help him 🙌 !
@grpython
@GroupAlliance
chotd1/1
Note this will be changed everyday. we are making this for whatsapp and telegram groups but sharing here for interested
+ 4
Ok here is some Python to encode/decode a secret message.
https://code.sololearn.com/cizLFE6klkn4
+ 4
Thanks Abdur - good suggestion - I'll make the change!
p.s. it's Ashton 😉
+ 3
Hmm natural language - as in actual words but in unintelligible order? I'm going to be scratching my head for quite a while with that one 🤔
+ 3
OK I think I get the gist of it. Here goes!
https://code.sololearn.com/cyT21dfsDBV8
+ 3
a super attempt Mr. Aston
i'll soon post mine
can you just modify so that even
"meet"
passes, not just Meet ? if msg.lower() == ...
more flexible, else great, i did not know you can input \n in sololearn. thanks (i always avoid user input in sl, i use variables)
+ 2
can you just make the output appear in a text area
*you are using web, so gui integrated can make it really useful so that users can copy their code from the <input>
✅ excellent solution !
+ 2
nice one Mr. David 👍🤜 the .join was excellent
+ 2
chotd1/1 line removal closed
NOTES
though uncommon a challenge, regex was also used. else going tge hard way might be += concatanation
thanks for participating . will make a past challenges soon
+ 2
nice but you know cipher challenges are becoming classic this is to spice up a bit
input : natural lang
output : natural lang
no worry
counted !
(awesome as always 👍🤜)
i am regrouping challenges here
https://code.sololearn.com/WSV2Qx27Yfil/?ref=app
+ 2
natural language is plain english
+ 2
i am here
can be encoded to
the dog was at the shop
+ 2
yes you decide your logic to fit a number of cases
you might want to have let us say 4 templates to begin with
then
a section dealing with pronouns i you etc
a section dealing with numbers
a section dealing with time
...
+ 2
by templates i mean random phrases to fit info