C# 알고리즘 코딩(프로그래머스)
프로그래머스 C# 나이 출력(파이썬)
라이프앤타임
2023. 3. 30. 11:35
using System;
public class Solution {
public int solution(int age) {
if (age > 120 || age <= 0)
{
throw new Exception("invalid param");
}
return 2023-age;
}
}
/////
파이썬
////
def solution(age):
return 2023-age