Why can't I write codes in Discussions? 🤔 | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 4

Why can't I write codes in Discussions? 🤔

Answering questions I am trying to insert a piece of code and nothing works. At the beginning, I thought that the problem was in one particular branch, but now I am convinced that I cannot do this anywhere.

25th Nov 2021, 12:19 AM
Solo
Solo - avatar
9 Answers
+ 3
Vasilly, Which language though? I remember experiencing this when trying to write PHP code directly within a response to a question. I would guess it's a part of security mechanism implemented by SoloLearn. I also remember moderator David Carrol mentioned that this was possible when an emoji was embedded within the raw code text. Though I'm not sure whether that trick will work for all languages. But personally, I'd prefer to save the code into a code bit to evade the hassle. P.S. Please add SoloLearn in the tags for context reference 👍
25th Nov 2021, 1:02 AM
Ipang
+ 3
My last answer was here: https://www.sololearn.com/Discuss/2929311/?ref=app And SoloLearn refused to accept an answer with a copy of the code snippet. I have 1200 programs written, and if I write programs for each question, it will double. Programming languages ​​do not matter, before that there were answers in Python, Java, C, C++...
25th Nov 2021, 2:32 AM
Solo
Solo - avatar
+ 3
Dear moderators, answer me. David Carroll, BroFar
26th Nov 2021, 8:52 AM
Solo
Solo - avatar
+ 3
BroFar, I tried duplicating your code and it printed. But why doesn't this code print: https://code.sololearn.com/ctZ8PeXzMZKH/?ref=app
26th Nov 2021, 10:13 AM
Solo
Solo - avatar
+ 3
Ipang, in both cases, the smiley trick was not good, but thanks for the answer anyway ☺️. And I can assume that the SoloLearn security service doesn't skip the script, but why didn't it skip the "Secret_Mission" code just because it has an ord() function ASCII?
26th Nov 2021, 10:50 AM
Solo
Solo - avatar
+ 3
BroFar thanks! ☺️
26th Nov 2021, 9:21 PM
Solo
Solo - avatar
+ 2
idk as I haven't experienced it myself Vasiliy & Ipang and as you know I too prefer to simply drop my scripts into a code_bit but I also write short scripts to answers. # array n = [5,4,6,1,1,8,2] # sum s=0 # digits in array for d in n: # if digits divisible by 2 equals zero if (d%2 == 0): # if condition met add digit to sum s += d # result print(s) I would say to screenshot and send an email to SoloLearn the next time the problem arises. https://code.sololearn.com/cywuUAQt8ETg/?ref=app
26th Nov 2021, 9:13 AM
BroFar
BroFar - avatar
+ 1
Vasiliy I passed it along for developers to review further .. Thanks 👍
26th Nov 2021, 9:02 PM
BroFar
BroFar - avatar
+ 1
Vasiliy /Василий в курсе, что я его передал ... АлКа Релова Это было абсолютно правильно, поскольку, похоже, существует некоторая проблема с деятельностью, которую SoloLearn может использовать по административным причинам. Они были проинформированы, и теперь решается вопрос о том, как они с этим справляются.
27th Nov 2021, 12:42 AM
BroFar
BroFar - avatar