[문자열 덧셈 계산기] 박성은 미션 제출합니다.#243
Open
SungeunP wants to merge 3 commits intowoowacourse-precourse:mainfrom
Open
Conversation
- `@woowacourse/mission-utils` 패키지의 `Console` 객체를 사용하여 `초기 질문 출력`, `문자열 입력` 기능을 수행하도록 한다. - 마찬가지로 예시 결과 출력도 `Console` 객체를 사용하여 요구사항대로 구현하고자 한다. - 예시 결과까지 출력하는 이유는 프로그램의 전체적인 뼈대를 잡고, 핵심 기능에 집중하기 위함이다.
- 프로그램의 전체적인 flow는 잡았으니, 핵심 기능(계산)에 집중한다. - 입력받은 string을 해석하는 기능을 구현한다. - divider를 기준으로 number 값을 구분하여 가져올 때마다 변수에 직접 합산하는 로직을 구현한다. - number 형을 다루는 로직인 만큼 예외처리를 적용하고 모듈화 했다.
- 요구사항에 따라 divider가 변수화 돼야 한다. 따라서 하드코딩된 divider를 변수화 하여, //<new_divider>\n 와 같은 형태로, "//"와 "\n" 사이에 존재하는 string을 divider로 사용한다. - 시간 내에 완성하지 못했습니다.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.