Lab4

Welcome in today’s lab i will demonstrate the way to have a function as an argument and make it so the letters displayed from the function are displayed backwards. Here are some pictures that verify this lab working.

 here shows program and what i used to accomplish it working.

 

and finally here shows the program running and being successful.

Now for this part of the lab i must write a function that takes a list of numbers and returns the cumulative sum; that is, a new list where the fifth element is the sum of the first i+1 elements from the original list. For example, the cumulative sum of [1, 2, 3] is [1, 3, 6].

this shows how the program is scripting in order for it to work. As you can see I used multiple methods I learned previously to help me with writing this program

And finally here shows the program running. I hope you enjoyed this lab !