SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
Search
Test your basic knowledge |
Basic Python Programming
Start Test
Study First
Subject
:
it-skills
Instructions:
Answer 50 questions in 15 minutes.
If you are not ready to take this test, you can
study here
.
Match each statement with the correct term.
Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.
This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. The extension for Python scripts
=
a%b
()
.py
2. Function to empty the contents of a file - no recovery is possible
truncate
insert()
()
|
3. This keyword begins a header for a body that repeats until the condition is no longer true.
Variables
and
not
while
4. deletes an item from a list
and
*=
%s
del
5. Less than symbol
*=
print()
argv
<
6. floor division AND assignment operator
//=
+=
open()
~
7. Greater than symbol
close
truncate
:
>
8. Function to write something to a file
//=
%=
<
write
9. Symbol to subtract things from each other
float
file.truncate()
#
-
10. exponentiation
a**b
del
del
n
11. exponent AND assignment operator
open()
<<
**=
~
12. Prints a string to the screen which will be Unicode.
%s
int()
%
/
13. Function to read the contents of a file
read
str
truncate
**=
14. Holds the value of something - e.g. oh_hi = 4 where oh_hi is the variable.
Variables
.py
format string
raise
15. Prints a string to the screen which is converted using repr()
%r
a//b
*readline
*=
16. prints its parameter to the console
print()
/=
n
|
17. Command to print to the screen
print
math.sqrt(a)
append()
a//b
18. This keyword creates a new class object which is a user-defined type - like a factory for creating objects.
class
a//b
input()
truncate
19. Called Logical AND operator. If both the operands are true then then condition becomes true. (a and b) is true.
input()
()
and
>>
20. Where the parameters go. A necessary punctuation after any function even if it's empty.
truncate
and
()
%=
21. subtract AND assignment operator
%
-=
&
argv
22. This keyword attempts to do something that would cause the program to crash if it were not for this statement.
try
%d
read
>=
23. Function to write something to a file
file.truncate()
write
=
format string
24. returns the length of a string (number of characters)
len()
%r
print()
%
25. A statement that displays a value on the screen.
/=
file.write(stuff)
()
print
26. End header line.
:
len()
>>
float
27. Symbol to add things together
>=
int()
+
input()
28. floor division
<=
*readline
a//b
return
29. Binary XOR Operator copies the bit if it is set in one operand but not both. (a ^ b) will give 49 which is 0011 0001
^
<=
==
Variables
30. A logical operator which returns a value of True if either of the conditions is true.
or
%r
**=
int
31. Prevents a runtime error from stopping the program.
*
append()
+
except
32. exponentiation
abs(a)
print()
a**b
is not
33. Writes stuff to the file.
math.sqrt(a)
*write(stuff)
=
>
34. This statement exits a function. The remaining lines of the function are not executed.
return
is
argv
.py
35. Binary OR Operator copies a bit if it exists in eather operand. (a | b) will give 61 which is 0011 1101
|
and
<<
-
36. Function to open or read a file
truncate
open()
<
or
37. Symbol to divide by the number to the right of the symbol
/
*
<=
read
38. A logical operator which requires two expressions to both be true.
>
and
**=
file.seek()
39. divide AND assignment operator
>>
or
*=
/=
40. ,multi-line comment hard-code,Fix (data or parameters) in a program in such a way that they cannot easily be altered by the user.
#
truncate
~
41. Less than symbol
=
/
<
open()
42. A logical operator which compares two operands and produces True if they are equal and False otherwise
a%b
print
open()
==
43. turns an object into a string
def
assignment
+=
str()
44. floor division AND assignment operator
//=
^
round()
*read
45. A built-in function that converts its argument to a string.
str
*read
del
abs(a)
46. Binary Ones Complement Operator is unary and has the efect of 'flipping' bits. (~a ) will give -60 which is 1100 0011
for
*
~
file.write(stuff)
47. Create a variable.
^
if
=
%s
48. assignment operator
**=
#
=
abs(a)
49. Modulus operator. It's the remainder after division
a**b
is
%
argument variable
50. inserts an item inside a list at a certain index
<
a**b
<<
insert()
Sorry!:) No result found.
Can you answer 50 questions in 15 minutes?
Let me suggest you:
Browse all subjects
Browse all tests
Most popular tests
Major Subjects
Tests & Exams
AP
CLEP
DSST
GRE
SAT
GMAT
Certifications
CISSP go to https://www.isc2.org/
PMP
ITIL
RHCE
MCTS
More...
IT Skills
Android Programming
Data Modeling
Objective C Programming
Basic Python Programming
Adobe Illustrator
More...
Business Skills
Advertising Techniques
Business Accounting Basics
Business Strategy
Human Resource Management
Marketing Basics
More...
Soft Skills
Body Language
People Skills
Public Speaking
Persuasion
Job Hunting And Resumes
More...
Vocabulary
GRE Vocab
SAT Vocab
TOEFL Essential Vocab
Basic English Words For All
Global Words You Should Know
Business English
More...
Languages
AP German Vocab
AP Latin Vocab
SAT Subject Test: French
Italian Survival
Norwegian Survival
More...
Engineering
Audio Engineering
Computer Science Engineering
Aerospace Engineering
Chemical Engineering
Structural Engineering
More...
Health Sciences
Basic Nursing Skills
Health Science Language Fundamentals
Veterinary Technology Medical Language
Cardiology
Clinical Surgery
More...
English
Grammar Fundamentals
Literary And Rhetorical Vocab
Elements Of Style Vocab
Introduction To English Major
Complete Advanced Sentences
Literature
Homonyms
More...
Math
Algebra Formulas
Basic Arithmetic: Measurements
Metric Conversions
Geometric Properties
Important Math Facts
Number Sense Vocab
Business Math
More...
Other Major Subjects
Science
Economics
History
Law
Performing-arts
Cooking
Logic & Reasoning
Trivia
Browse all subjects
Browse all tests
Most popular tests