GithubHelp home page GithubHelp logo

java-baseball's Introduction

숫자 야구 게임

1. 주요 클래스 설명


BaseballNumber

  • 숫자를 가져올 수 있는 메소드를 명세한 인터페이스
  • 구현체 : AnswerNumber , InputNumber

AnswerNumber

  • 임의의 수(야구게임의 정답)를 생성하고 저장
  • 저장된 숫자를 가져올 수 있음

InputNumber

  • 입력한 값을 저장하고 유효성을 검증
  • 저장된 숫자를 가져올 수 있음

BaseballResult

  • 스트라이크/볼 카운트를 저장
  • 정답(AnswerNumber)과 입력값(InputNumber)를 비교하여 카운트를 체크
  • 체크 결과를 저장

GameCenter

  • 게임 시작/진행/종료/재시작을 총괄하는 컨트롤 센터

2. 기능 설명


(1). 입력값 유효성 검증

  • 입력한 값을 저장하고 유효한 값인지 검증

(2). 정답 숫자 생성

  • 랜덤의 숫자를 생성하고 저장

(3). 입력값 체점

  • 스트라이크 판별
  • 볼 판별
  • 낫싱/정답 판별

(4). 결과 출력

  • 체점 결과 출력 기능

(5). 게임 컨트롤

  • 게임 시작
  • 게임 진행
  • 게임 종료/재시작

java-baseball's People

Contributors

rockjoon avatar pobiconan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.