
[문제] [풀이] - 이건 내가 직접 풀었다. 내 풀이는 아래와 같다. class Solution { public int solution(int[] common) { int answer = 0; int one = common[0]; int two = common[1]; int thr = common[2]; if((two - one) == (thr - two)) { answer = common[common.length - 1] + (two - one); } else { answer = common[common.length - 1] * (two / one); } return answer; } } - 쉬운 문제라 다른 사람의 풀이도 다 비슷비슷했다. - 아래의 풀이는 변수 선언을 적게하는 풀이다.(난 3개 선..
흥미/코딩테스트
2023. 1. 30. 00:05
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- git
- 운영체제
- 빅데이터
- node.js
- 프로세스
- MongoDB
- 코딩테스트
- 빅데이터 분석기사
- Phaser
- db
- Spring Boot
- nosql
- MySQL
- 자료구조
- 메모리
- Java8
- Stream
- java
- 코테
- API
- 프로그래머스
- SpringBoot
- SQL
- Phaser3
- DART
- spring
- Advanced Stream
- OS
- 알고리즘
- jpa
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 | 31 |
글 보관함