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. unction to read one line of a file






2. Function to empty the contents of a file - no recovery is possible






3. Function to write something to a file






4. Reads just one line of a text file.






5. prints its parameter to the console






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






7. Symbol to divide by the number to the right of the symbol






8. modulo






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






10. unction to read one line of a file






11. modulus AND assignment operator






12. subtract AND assignment operator






13. Adds something to a variable






14. floor division






15. Evaluates to false if the variables on either side of the operator point to the same object and true otherwise. x is not y - here is not results in 1 if id(x) is not equal to id(y).






16. deletes an item from a list






17. Binary Ones Complement Operator is unary and has the efect of 'flipping' bits. (~a ) will give -60 which is 1100 0011






18. exponentiation






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






20. A built-in function that converts integers and strings to floating-point numbers.






21. exponentiation






22. A boolean operator that takes two strings and returns True if the first appears as a substring in the second.






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






24. Symbol used to create comments






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






26. Less than or equal to symbol






27. Binary Left Shift Operator. The left operands value is moved left by the number of bits specified by the right operand. a << 2 will give 240 which is 1111 0000






28. Reads the contents of the file you can assign the result to a variable.






29. Function to open or read a file






30. modulus AND assignment operator






31. adds an item to a list






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






33. A data type for representing numbers with fractional values.






34. Create a variable.






35. assignment operator






36. Binary AND Operator copies a bit to the result if it exists in both operands. (a & b) will give 12 which is 0000 1100






37. Less than or equal to symbol






38. exponent AND assignment operator






39. floor division AND assignment operator






40. Evaluates to true if it finds a variable in the specified sequence and false otherwise. x in y - here in results in a 1 if x is a member of sequence y.






41. assignment operator






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






43. empties the file






44. An operator to check whether two variables refer to the same object.






45. A statement that breaks out of a loop.






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






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






48. 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






49. A statement that ends the current iteration of a loop but continues looping.






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







Sorry!:) No result found.

Can you answer 50 questions in 15 minutes?


Let me suggest you:



Major Subjects



Tests & Exams


AP
CLEP
DSST
GRE
SAT
GMAT

Most popular tests