Notice
Recent Posts
Recent Comments
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- hackerrank
- leetcode
- gs25
- 파이썬
- 맥북
- Real or Not? NLP with Disaster Tweets
- 편스토랑 우승상품
- 우분투
- 프로그래머스 파이썬
- SW Expert Academy
- 코로나19
- 자연어처리
- 백준
- 편스토랑
- ChatGPT
- Baekjoon
- programmers
- 더현대서울 맛집
- 금융문자분석경진대회
- dacon
- 캐치카페
- Git
- PYTHON
- 데이콘
- AI 경진대회
- Kaggle
- ubuntu
- Docker
- 프로그래머스
- github
Archives
- Today
- Total
솜씨좋은장씨
[BaekJoon] 6749번 : Next in line (Python) 본문
728x90
반응형

코딩 1일 1문제! 오늘의 문제는 백준의 Next in line 입니다.
6749번: Next in line
You know a family with three children. Their ages form an arithmetic sequence: the difference in ages between the middle child and youngest child is the same as the difference in ages between the oldest child and the middle child. For example, their ages c
www.acmicpc.net
👨🏻💻 코드 ( Solution )
def next_in_line(youngest_age, middle_age):
return 2 * middle_age - youngest_age
if __name__ == "__main__":
youngest_age = int(input())
middle_age = int(input())
print(next_in_line(youngest_age, middle_age))
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
'Programming > 코딩 1일 1문제' 카테고리의 다른 글
[BaekJoon] 14645번 : 와이버스 부릉부릉 (Python) (0) | 2022.05.11 |
---|---|
[BaekJoon] 8370번 : Plane (Python) (0) | 2022.05.10 |
[BaekJoon] 5523번 : 경기 결과 (Python) (0) | 2022.05.08 |
[BaekJoon] 1235번 : 학생 번호 (Python) (0) | 2022.05.07 |
[BaekJoon] 14918번 : 더하기 (Python) (0) | 2022.05.06 |