Final Flashcards
Bubble Sorting
Repeatedly swapping adjacent elements until all elements are in the right order
Insertion Sorting
Swaps adjacent elements with the inner while loop swapping the current element backwards through the list until it encounters a smaller element
Ord Function
Convert a single character (string) to an integer
String must be one character long
Chr Function
Convert an integer back to a character (string)
Integer must be a positive number
Histogram
plt.hist(data)
Line Plot
plt.plot(data)
Scatter Plot
plt.scatter(exam1,exam2)
Labeling
plt.xlabel(“Time”)
plt.ylabel(“Money”)
plt.title(“Money over Time”)
Recursion
Process in which the result of each repetition is dependent upon the result of the next repetition
Recursive Call
When the function being defined is used in its own definition
Branch
A logical decision in code to do different things based on a condition
Combination
To bring together the results of the recursive calls and the current element
Simplification
The process of reducing down the original argument before the recursive call
Base Case
The simpler branch of a recursive function, where the recursion terminates with a single value
Recursive Case
The other branch of a recursive function, where the recursive call and combination happens