Programing Exercise: Test Your Programing Language Proficiency
Things you should be able to do without looking up:
- print version number within a script
- list available modules
- list module search path
- list module imported symbols
- from terminal, display module doc
- from terminal, display doc of python lang keywords: while, for, list, dict….
- List all string methods, list/array methods, hash/dictionary methods. Or, functions.
- extract substring by index.
- find the floor diversion of 2 floats. Find remainder of them.
- find square root, 3rd root.
- convert int ↔ float, int ↔ string, float ↔ string. (if the lang does not do. If it does, specify which types are auto-converted)
- print without newline
- list all possible values that evaluate to true, in boolean context. (give a general description)
- write if then else, while, loop, also use break.
- solve http://en.wikipedia.org/wiki/Levenshtein_distance
- list operations: length, access/change/delete/insert a element by index.
- list operations: access/delete/insert a sublist from index i to j. Replace sublist from index i to j. join 2 lists. Append/prepend a list.
- list operations: check if element exist, find indexes by value, count number of occurrence, delete elements by value, find min/max item.
- list operations: push, pop, pop ith, shift, unshift,
- hash operations: get length, access/add/modify/delete a entry by key, check if key exist.
- hash operations: get all keys, get all values.
- define function with named params, optional params, infinite params
- loop thru list values. loop thru list with index and values.
- loop thru dictionary, with key and value.
- master python regex.
- finish a tutorial on string methods
- how to find interpreter path from runing script
- how to find runing script's path
- how to find a module's path
- sort a list
- sort a matrix by 2nd column (list of lists)
Object Oriented Programing
- write a class.
- write a initializer or constructor
- create class variable (aka static variable)
- create instance variable
- define a method
- create a object
- extend a class.
- given 2 class A and B, find if A is the child of B.
- check if a object O is a instance of class C.
- check if 2 objects are identical
If you have a question, put $5 at patreon and message me.