ramkrishan-sahu / fsdse-python-assignment-2

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Python Programming Basics - Assignment

Problem Statement:

Write a function to find pair sum in a list.

  1. Define function 'pairSum' which will accept two arguments, a integer list and a number.
  2. List should have at least two elements in it.
  3. Function should return pair of integers within list having sum equal to given number as argument.
  4. 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)]
    

About


Languages

Language:Python 100.0%