관리 메뉴

솜씨좋은장씨

[BaekJoon] 26545번 : Mathematics (Python) 본문

Programming/코딩 1일 1문제

[BaekJoon] 26545번 : Mathematics (Python)

솜씨좋은장씨 2022. 12. 21. 12:21
728x90
반응형

코딩 1일 1문제! 오늘의 문제는 백준의 Mathematics 입니다.

 

26545번: Mathematics

A mathematician has stolen your calculator! Luckily, you know how to code and can write a program that adds together numbers. Write a program that adds together a list of integers.

www.acmicpc.net

👨🏻‍💻 코드 ( Solution )

def mathematics(number_list):
    return sum(number_list)


if __name__ == "__main__":
    number_list = []
    
    for _ in range(int(input())):
        number = int(input())
        
        number_list.append(number)
        
    print(mathematics(number_list=number_list))
 

GitHub - SOMJANG/CODINGTEST_PRACTICE: 1일 1문제 since 2020.02.07

1일 1문제 since 2020.02.07. Contribute to SOMJANG/CODINGTEST_PRACTICE development by creating an account on GitHub.

github.com

Comments