This repository contains a collection of Scheme code which covers topics such as functional programming paradigms, recursion, mathematical computations, and list manipulation.
- Functions
- Final Fantasy Calculation Functions
- Recursive Math
- List Manipulation
- Multiply Number List
- Functions as Parameters
run1: Addition of three numbers.run2: Complex mathematical expression involving multiplication and addition.run3: Mathematical expression with subtraction and division.run4: Another complex mathematical expression.run5: Yet another complex mathematical expression.
ffMQ-Damage: Calculate damage in the Final Fantasy game based on attack, defence, weakness, and targets.ff10-baseDamage: Calculate base damage in Final Fantasy X.ff10-defenseNum: Calculate the defence number in Final Fantasy X.ff10-reduceDamage: Reduce damage in Final Fantasy X.ff10-finalDamage: Calculate final damage in Final Fantasy X.ff10-calculate-damage: Overall damage calculation function in Final Fantasy X.
factorial: Recursive factorial calculation.alt-factorial: Alternative recursive factorial calculation.
get-second-item: Retrieve the second item from a list.get-third-item: Retrieve the third item from a list.
list-length?: Calculate the length of a nested list.
arbitrary-cdr: Retrieve the Cdr of a list based on a given number.
make-list: Create a list with repeated elements.
number-list?: Check if a list is a valid number list.multiply-number-list: Multiply numbers in a valid number list.
which-function: Compare two functions based on their results for a given input.