Title Construct a function that returns a list of remainders from the input.
Catalog Type SLCItem
Persistent ID https://adapt2.sis.pitt.edu/acos/pitt/jsparsons/jsparsons-python/ps?example-id=ps_python_list_of_remainders1
Platform Name jsParsons
Features
Description Construct a function which calculates the remainder of each element of the first list and the element with the same index in the second list. The remainders are stored in a new list. If the number in the second list is 0, the function should directly add number 2 to the new list instead of the remainder.
Keywords
Author Kamil Akhuseyinoglu
Institution University of Pittsburgh
Iframe URL https://adapt2.sis.pitt.edu/acos/pitt/jsparsons/jsparsons-python/ps?example-id=ps_python_list_of_remainders1&grp=demo&usr=demo&sid=-1&cid=-1
Protocol PITT
Protocol URL
License MIT
Programming Language Python
Natural Language en

Preview