How it works? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 15

How it works?

Among the tests there is such a question. x=[] for y in range(12): if y[b] %[/b] 2 == 0: x.append(y) continue print(x) What is [b] and [/ b], what does it do. The interpreter gives an error.

11th Sep 2019, 9:23 AM
Mikhail Gorchanyuk
Mikhail Gorchanyuk - avatar
4 Answers
+ 16
Seriously it makes zero sense. A long time ago I have reported this question and still it hasn't been taken down. Many other questions have answers that are quite wrong, but this is wrong beyond measure.
11th Sep 2019, 9:24 AM
👑 Prometheus 🇸🇬
👑 Prometheus 🇸🇬 - avatar
+ 10
It's just a case of "people weren't very aware of the mistake" when they approved the quiz, whoever "they" is.
11th Sep 2019, 9:29 AM
👑 Prometheus 🇸🇬
👑 Prometheus 🇸🇬 - avatar
+ 9
Thank. I even tried in python 2.6, but it still doesn't work
11th Sep 2019, 9:27 AM
Mikhail Gorchanyuk
Mikhail Gorchanyuk - avatar
0
how do this work??
17th Nov 2020, 7:22 PM
Raul Nevarez