Sigmoid Activation From Scratch
Difficulty: Easy · Concept: Activation Functions — Historical / Saturating Functions
Sigmoid squashes any real number into — rarely used in hidden layers today (see the concept page for why), but still standard for a binary classifier's output layer, where the output needs to read as a probability. It's also the same function Logistic Regression is built on.
Your task: implement sigmoid(z) for a single real number z, using math.exp (no NumPy).
Next: Sigmoid Derivative (Vectorized, Numerically Stable) (a harder variant), or skip ahead to Numerically Stable Softmax From Scratch