Python Programming Basics
English
Basic
A quiz assessing students understanding of basic Python.
Description
30
Questions
30 sec
Per question
6:17
Average time
3.0
Contest Score
3.5
Community Rating
43
Participants
10 comments
Small Lizard
What type error is it, if your code doesn't compile?
* syntax error
* logic error
* run-time error
* binary error
Explanation: A TypeError occurs when an operation or function is applied to an object of inappropriate type.

Why explanation is about TypeError but options are other errors?
Small Lizard
Which of these statements would assign a string value to the variable MyName?
MyName = ("Horatio") is also correct answer: https://ideone.com/ey79aL
Hi, I think there's an error with question 13. It looks like it is using the same question as 12 because they both say "How many variables are there in this piece of code?" but it does not make sense in question 13. In question 13 there is only one variable for "age" but the answer is "1414141414".
Small Lizard
Questions "What is the output after running this code, if the user enters the number 30?" and "Password Checker"
Actually, after running these codes, there will be extra output: "Please enter a number:" and "Welcome...\n***...\nPress..." respectively
Small Lizard
num=3
while True: ...
Here, loop will run forewer. Probably you skipped 2 indents (in 2 last lines).
Ace Sloth author
Hello, Thank you for your valuable comments, there’s a mistake with a question but I can’t edit the question. The others are understandable but I can make them more clear.
Small Lizard
class Demo: ...
Analyze the given code
This code will give SyntaxError because of Demo(''Hello''), there is two apostrophes on each side of Hello
Small Lizard
3 questions match with questions from other quiz
Proof: https://telegra.ph/3-same-questions-in-two-quizzes-05-28
Cool Bear
I noticed that one of the questions (https://imgur.com/ncXait4) didn't make sense as you used the term "indent" wrong. You asked: "Which of these statements repeats indented code 6 times?" The definition of the word can be found here: shorturl.at/fruV5 and you will notice that as it is used by you here it doesn't make sense.
Cool Bear
In this question: https://imgur.com/8OjI6k7 you ask "how many variables are there in this piece of code ?" There is only one variable namely "age" so the answer "1414141414" and so are the other options "70", "60" and "141414". I believe you may have made a mistake by asking the wrong question that was not intended for the answer options you provided.
Take the quiz to leave a comment