Test your basic knowledge |

Basic Python Programming

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. Modulus operator. It's the remainder after division






2. Function to close a file - it will not be able to be used again unless the file is opened.






3. Create a variable.






4. A logical operator which compares two operands and produces True if they are equal and False otherwise






5. floor division AND assignment operator






6. A keyword that does nothing but fill space to indicate code which will be written later.






7. Greater than or equal symbol.






8. exponent AND assignment operator






9. Function to open or read a file






10. Greater than or equal symbol.






11. This keyword begins the simplest form of a conditional statement.






12. Symbol used to create comments






13. multiply AND assignment operator






14. A statement that breaks out of a loop.






15. asks the user for a response and returns that response






16. The keyword beginning a header that will create a loop.






17. Function to read the contents of a file






18. A logical operator which compares two operands and produces True if they are equal and False otherwise






19. Holds the value of something - e.g. oh_hi = 4 where oh_hi is the variable.






20. writes stuff to the file






21. Reads just one line of a text file.






22. prints its parameter to the console






23. Writes stuff to the file.






24. assignment operator






25. This keyword in the body of a conditional - gives an alternative execution.






26. Symbol used to create comments






27. exponentiation






28. divide AND assignment operator






29. End header line.






30. Prints a string to the screen which will be Unicode.






31. A logical operator which returns a value of True if either of the conditions is true.






32. deletes an item from a list






33. Binary OR Operator copies a bit if it exists in eather operand. (a | b) will give 61 which is 0011 1101






34. A statement that assigns a value to a variable.






35. Function to write something to a file






36. This keyword begins the simplest form of a conditional statement.






37. The keyword beginning a header that will create a new function.






38. Binary OR Operator copies a bit if it exists in eather operand. (a | b) will give 61 which is 0011 1101






39. square root






40. Less than or equal to symbol






41. Holds the value of something - e.g. oh_hi = 4 where oh_hi is the variable.






42. A logical operator which requires two expressions to both be true.






43. returns the length of a string (number of characters)






44. An operator that removes a value from a list.






45. multiply AND assignment operator






46. Less than or equal to symbol






47. turns an object into a string






48. Prints a string to the screen which is a signed decimal.






49. Prints a string to the screen which will be Unicode.






50. prints its parameter to the console