Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[자동차 경주] 남인우 미션 제출합니다. #2374

Open
wants to merge 21 commits into
base: main
Choose a base branch
from

Commits on Oct 27, 2023

  1. Configuration menu
    Copy the full SHA
    31fb897 View commit details
    Browse the repository at this point in the history

Commits on Oct 28, 2023

  1. Configuration menu
    Copy the full SHA
    5c0eda7 View commit details
    Browse the repository at this point in the history
  2. feat(RacingCar): 0부터 9까지 랜덤 값을 구하는 기능 구현

    1. RacingCar 클래스 생성
    2. 0부터 9까지 랜덤 값을 구하는 함수 makeRandomNumber 구현
    korean5078 committed Oct 28, 2023
    Configuration menu
    Copy the full SHA
    9596525 View commit details
    Browse the repository at this point in the history
  3. feat(RacingCar): 무작위 숫자가 4부터 9가 나오면 전진하는 기능 구현

    1. RacingCar의 randomNumber가 4이상인 경우 전진하는 함수 goOrStop 구현
    korean5078 committed Oct 28, 2023
    Configuration menu
    Copy the full SHA
    df262df View commit details
    Browse the repository at this point in the history
  4. docs: 기능 명세서 수정

    1. RacingCar 클래스에서 생성자를 통해 이름을 부여할 수 있는 기능 이미 구현됨
    korean5078 committed Oct 28, 2023
    Configuration menu
    Copy the full SHA
    e6e1381 View commit details
    Browse the repository at this point in the history

Commits on Oct 30, 2023

  1. feat(Player): 각 자동차에 부여할 이름 입력 기능 구현

    1. Player 클래스 생성
    2. 각 자동차에 부여할 이름을 입력하는 inputNames 함수 구현
    3. 이름이 5자 이상 입력되면 예외 발생하는 함수 validateName 함수 구현
    4. 기능 명세서 수정
    korean5078 committed Oct 30, 2023
    Configuration menu
    Copy the full SHA
    409fe60 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    0ac9398 View commit details
    Browse the repository at this point in the history
  3. feat(Player): 자동차들의 이동 횟수를 입력하는 기능 구현

    1. 자동차들의 이동 횟수를 입력하는 inputNumberOfRounds 함수 구현
    2. 기능 명세서 수정
    korean5078 committed Oct 30, 2023
    Configuration menu
    Copy the full SHA
    6a91747 View commit details
    Browse the repository at this point in the history

Commits on Oct 31, 2023

  1. Configuration menu
    Copy the full SHA
    4d66eb4 View commit details
    Browse the repository at this point in the history
  2. feat(RacingCarGame): 플레이어에게 이름을 입력받으면 자동차 객체들을 생성하는 기능 구현

    1. 플레이어에게 이름을 입력 받으면 자동차 객체들을 해당 개수만큼 생성하는 함수 createRacingCars 함수 구현
    korean5078 committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    3483923 View commit details
    Browse the repository at this point in the history
  3. feat(RacingCarGame,RacingCar): 플레이어에게 입력받은 라운드 횟수만큼 게임을 실행하는 기능 구현

    1. RacingCarGame 클래스에서 라운드마다 자동차가 전진 또는 멈추는 roundStart 함수 구현
    2. RacicngCar 클래스에서 이름과 거리를 출력하는 printDistance 함수 구현
    3. RacingCarGame 클래스에서 라운드마다 각 자동차의 이름과 거리를 출력하는 printRoundScore 함수 구현
    4. RacingCarGame 클래스에서 전체적인 게임을 실행하는 init 함수 구현
    korean5078 committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    4adfae2 View commit details
    Browse the repository at this point in the history

Commits on Nov 1, 2023

  1. feat(RacingCarGame): 라운드가 모두 끝나면 최종 우승자를 가리고 출력하는 기능 구현

    1. RacingCarGame 클래스에서 최종 라운드에서 거리가 가장 긴 자동차를 찾는 함수 chooseWinner 구현
    2. RacingCarGame 클래스에서 우승한 자동차의 이름을 출력하는 함수 printWinnerName 구현
    3. RacingCar 클래스에서 이름을 반환하는 gettter 함수 추가
    korean5078 committed Nov 1, 2023
    Configuration menu
    Copy the full SHA
    86401e6 View commit details
    Browse the repository at this point in the history
  2. refactor(RacingCarGame): 최종 우승자를 가리는 기능 함수 수정

    1. chooseWinner 함수가 한 가지 일만 하도록 가장 높은 거리 값을 구하는 기능을 getHighestDistance 함수로 이동
    korean5078 committed Nov 1, 2023
    Configuration menu
    Copy the full SHA
    e8499da View commit details
    Browse the repository at this point in the history
  3. refactor(RacingCar): 자동차가 전진하거나 멈추는 기능 함수 수정

    1. makeRandomNumber 함수 접근 제한자를 private로 수정
    2. goOrStop 함수에서 makeRandomNumber 함수 실행
    korean5078 committed Nov 1, 2023
    Configuration menu
    Copy the full SHA
    822d457 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    8dcea68 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    fd41d09 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    7f98b80 View commit details
    Browse the repository at this point in the history
  7. fix(Player): Player 클래스 함수 수정

    1. 끝에 ','가 있으면 예외를 발생시키는 함수 validateLine 구현 및 inputNames 함수에 적용
    2. 예외를 발생시키는 함수마다 예외를 던지게끔 코드 수정
    korean5078 committed Nov 1, 2023
    Configuration menu
    Copy the full SHA
    cc3a4b1 View commit details
    Browse the repository at this point in the history
  8. refactor(RacingCarGame): init 함수 기능 분리

    1. init 함수에서 게임 라운드 마다 반복하는 코드를 startGameRounds 함수를 새로 만들어서 분리
    korean5078 committed Nov 1, 2023
    Configuration menu
    Copy the full SHA
    a9913ff View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    8b65bae View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    f0b8ec6 View commit details
    Browse the repository at this point in the history