Skip to content
Snippets Groups Projects
Commit a1ac3aa3 authored by Iida Pyykkönen's avatar Iida Pyykkönen
Browse files

added 14

parent 7fe23172
No related branches found
No related tags found
No related merge requests found
# Write a function solve that returns the running sum of a list.
# The running sum is the sum of all elements up to each index.
def solve(nums):
result = [nums[0]]
for i in range(1, len(nums)):
......
14.py 0 → 100644
# Write a function solve that reverses the words in a string.
# Words are separated by spaces.
def solve(string):
list = reversed(string.split())
return ' '.join(list)
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment