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. exponent AND assignment operator
a%b
**=
#
<
2. A statement that displays a value on the screen.
file.seek()
#
print
round()
3. modulo
%
read
<=
a%b
4. Less than or equal to symbol
<=
print()
len()
n
5. Greater than or equal symbol.
try
>=
format string
round()
6. inserts an item inside a list at a certain index
str()
%d
insert()
~
7. floor division AND assignment operator
//=
==
for
a//b
8. Less than symbol
/
<
%
del
9. This keyword in the body of a conditional - gives an alternative execution.
for
else
argv
+=
10. Holds the value of something - e.g. oh_hi = 4 where oh_hi is the variable.
>=
Variables
a//b
<=
11. This statement causes an exception.
raise
if
not in
abs(a)
12. absolute value
file.write(stuff)
abs(a)
<=
&
13. Function to close a file - it will not be able to be used again unless the file is opened.
/
=
close
%r
14. Symbol to add things together
+
:
del
|
15. This keyword attempts to do something that would cause the program to crash if it were not for this statement.
:
try
%
&
16. Less than or equal to symbol
=
<=
<
-
17. Adds something to a variable
break
pass
len()
=
18. unction to read one line of a file
truncate
else
/
readline
19. floor division
and
=
a//b
*
20. A data type for representing numbers with fractional values.
-=
()
floating point number
except
21. A statement that ends the current iteration of a loop but continues looping.
is not
%r
<
continue
22. Symbol to divide by the number to the right of the symbol
.py
/
len()
//=
23. A built-in function that converts its argument to a string.
in
%s
*=
str
24. asks the user for a response and returns that response
elif (Else if)
input()
=
.py
25. Create a variable.
=
%r
|
else
26. modulus AND assignment operator
not
%=
/
for
27. This keyword in the body of a conditional allows chained conditionals.
elif (Else if)
//=
input()
truncate
28. multiply AND assignment operator
*readline
*=
a**b
Variables
29. End header line.
**=
str
:
>=
30. Symbol to subtract things from each other
-
%
a%b
>=
31. prints its parameter to the console
()
or
print()
*=
32. This keyword begins the simplest form of a conditional statement.
if
+=
%=
()
33. Symbol to multiply things
*
%
>>
del
34. divide AND assignment operator
-=
/=
and
-
35. Where the parameters go. A necessary punctuation after any function even if it's empty.
truncate
is not
*truncate
()
36. A string that begins with the % symbol and contains a sequence of printable characters and format specifiers that determine how values output should look.
format string
%s
class
<<
37. Symbol used to create comments
//=
print
#
38. Prints a string to the screen which is a signed decimal.
*
Variables
==
%d
39. The keyword beginning a header that will create a loop.
%=
+=
is
for
40. returns the length of a string (number of characters)
len()
+=
del
=
41. Argument variable
argv
*read
=
=
42. A logical operator which returns a value of True if either of the conditions is true.
argv
or
def
a**b
43. Adds a new line character
**=
read
n
<=
44. Function to read the contents of a file
write
#
append()
read
45. This statement exits a function. The remaining lines of the function are not executed.
round()
read
return
a**b
46. Empties the file - watch out if you care about the file.
*truncate
else
#
=
47. The keyword beginning a header that will create a new function.
def
()
.py
:
48. asks the user for a response and returns that response
input()
*=
int
#
49. subtract AND assignment operator
<=
<
str()
-=
50. inserts an item inside a list at a certain index
<
read
int()
insert()