level 1. add

on under algorithm
1 minute read

[level 1] add

문제

Write a function that returns the sum of two numbers.

Example

For param1 = 1 and param2 = 2, the output should be add(param1, param2) = 3.

Input/Output

  • [time limit] 4000ms (py3)
  • [input] integer param1

Guaranteed constraints: -100 ≤ param1 ≤ 1000.

  • [input] integer param2

Guaranteed constraints: -100 ≤ param2 ≤ 1000.

  • [output] integer

The sum of the two inputs.

내 답안

def add(param1, param2):
    return param1 + param2

다른 사람의 답안

def add(param1, param2):
    return param1 + param2

배울점, 느낀점

  • 1단계 시작이니까..

출처

https://codefights.com/

algorithm
comments powered by Disqus