+ 26

Bad coding conventions in quizzes (first question on SoloLearn iOS app)

I notice a lot of bad coding practises in challenges. Do you think even if the question itself is good, but the naming practises are bad, should they be rejected? In Python it’s very bad. People make a variable called list and use the list() function. In Python, doing so will not return an error but instead, for the context of the code, the function list will be replaced by a variable list so, the answer itself will be affected at times!

3rd Dec 2017, 2:27 AM
👑 Prometheus 🇾🇬
👑 Prometheus 🇾🇬 - avatar
6 Answers
+ 14
Perhaps the worst thing about challenges is that so many of them have been designed for misleading rather than teaching new concepts and techniques.
3rd Dec 2017, 12:05 PM
Vahid Shirbisheh
Vahid Shirbisheh - avatar
+ 8
Yes I agree. In my opinion questions like that are a waste of time. They could encourage people to pickup bad habits. I don't like the c++ challenge questions where they give a class a name like A, and then give it a function with the same name. Then maybe overload the function as well. (also there will not be comments, although kind of makes sense for a What does this code do question) Why? This takes the focus away from understanding object oriented programming, and on to debugging poorly written code. You would never have caught me writing messy code like that 10 years ago, and I write much cleaner code now!
3rd Dec 2017, 3:22 AM
Jared Bird
Jared Bird - avatar
+ 7
Some good points here. I would encourage all of you to contribute questions that promote good coding practices in Quiz Factory.
3rd Dec 2017, 7:34 PM
Eric Blinkidu
Eric Blinkidu - avatar
+ 2
Sometimes coding itself becomes bad and even worse because of such practices. One such example is using variable or function name as value which is a keyword in Javascript. So such cases should be filtered properly
3rd Dec 2017, 5:43 AM
Arunkumar Palanisamy
Arunkumar Palanisamy - avatar
+ 2
Right! Not only in python but in other languages too! I think moderators should concern over this thing
5th Dec 2017, 5:23 AM
#RahulVerma
#RahulVerma - avatar
0
I'm agree
6th Dec 2017, 3:43 AM
gameDisatrous Directorinc
gameDisatrous Directorinc - avatar