Task 1: Partial Sums Implement a function partial_sum(start, end, step) that takes three integers and returns the partia
Posted: Mon Jul 11, 2022 9:49 am
Task 1: Partial Sums Implement a function partial_sum(start, end, step) that takes three integers and returns the partial sum of a sequence. The function will return the sum of the sequence of numbers that starts at start, ends at end (inclusive), and goes up by step. Hint: how can you use a conditional to ensure that end is always included, no matter whether the step is positive or negative? Example: calling partial_sum (3, 13, 2) returns 48 because 3+5+7+9+11+ 13 = 48.