[프로그래머스 | Lv.0] 나이 출력

728x90
https://school.programmers.co.kr/learn/courses/30/lessons/120820

 

 

📝 나의 풀이

using System;

public class Solution {
    public int solution(int age) {
        int answer = 2023-age;
        return answer;
    }
}
  • 문제는 2022년도지만 2023년도로 풀어야 정답처리가 된다.
728x90