Write a function to find pair sum in a list.
- Define function 'pairSum' which will accept two arguments, a integer list and a number.
- List should have at least two elements in it.
- Function should return pair of integers within list having sum equal to given number as argument.
- Function should pass all test cases.
Instructions:
-
Program should be written in file pair_sum.py
-
Function name should be pairSum.
-
Input
Type: List Value: ([1,2,3,4], 5)
-
Expected Output
Type: List Value: [(1,4), (2,3)]