Python Fundamentals/Functions

Functions

0/2 exercises
Exercise 1 of 2

Basic Functions: Math Helpers

defparametersreturndefault argumentsdocstringslambda

Write two functions:

  1. power(base, exponent) — returns base raised to the power of exponent
  2. is_divisible(n, divisor) — returns True if n is evenly divisible by divisor, False otherwise