Giter Site home page Giter Site logo

solitaire-solver's Introduction

# solitaire-solver
* 운영체제: Ubuntu 20.04 LTS
* 컴파일러: g++ (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0
* make: GNU Make 4.2.1

## 컴파일 및 실행
```bash
make
./main (시드 값)
```

시드 값을 지정하지 않으면 0으로 설정됩니다.

## 출력
### 초기 세팅

(stock) (waste)        (output-스페이드, 하트, 클로버, 다이아몬드)

(playing #1) (playing #2) ... (playing #7)
             (playing #2) ... (playing #7)
                          ... (playing #7)
                              (playing #7)

이때 파란색 글자는 카드가 뒤집어져 있다는 것을 의미합니다.

예시)
◆ Q                                
                                   
♠ Q  ◆ A  ♥ 2  ♣ 3  ♣ K  ♥ 3  ♠ 4  
      ♠ A  ♣ A  ♠ K  ♥ K  ♣ J  ◆ 2  
            ♠ 3  ◆ K  ♠ 5  ◆ 3  ♥ 5  
                  ♥ 6  ♠ 6  ♣ 7  ♣ 2  
                        ◆ J  ♠ 8  ♥ 7  
                              ♣ 6  ◆ 9  
                                    ♥ J

### 카드 이동
예시 1)
-------------------------------------------------
1: ♠ A  [playing #2 →  output] (score: -52 →  -47)

◆ Q            ♠ A                 
                                   
♠ Q  ◆ A  ♥ 2  ♣ 3  ♣ K  ♥ 3  ♠ 4  
            ♣ A  ♠ K  ♥ K  ♣ J  ◆ 2  
            ♠ 3  ◆ K  ♠ 5  ◆ 3  ♥ 5  
                  ♥ 6  ♠ 6  ♣ 7  ♣ 2  
                        ◆ J  ♠ 8  ♥ 7  
                              ♣ 6  ◆ 9  
                                    ♥ J 

예시 2)
-------------------------------------------------
64: ◆ J  [playing #6 →  playing #3] 
64: ♠ 10 [playing #6 →  playing #3] 
64: ◆ 9  [playing #6 →  playing #3] 

      ♣ 7        ♠ A  ♥ 2  ♣ 3       
                                   
◆ K  ♠ K  ♥ K  ♠ 6  ♣ K  ♠ 4  ♥ 3  
♣ Q  ◆ Q  ♠ Q  ♣ 5  ♥ Q  ♥ 7  ♥ 5  
♥ J  ♣ J  ◆ J  ◆ 4  ♠ J  ◆ A       
♣ 10 ◆ 10 ♠ 10       ♥ 10           
♥ 9  ♣ 9  ◆ 9        ♠ 9            
♠ 8  ♥ 8                           
◆ 7  ♠ 7                           
♣ 6  ♥ 6                           
◆ 5  ♠ 5                           
♣ 4  ♥ 4                           
◆ 3  ♠ 3                           
      ◆ 2

움직인 카드, 출발 위치, 도착 위치, 카드가 움직인 후의 게임판을 보여줍니다.
점수가 올라가는 경우, 점수를 같이 보여줍니다.

여러 장의 카드 뭉치를 움직일 때는 '예시 2'와 같이 표시합니다.

### 결과
예시 1)
game over!
score: -17

예시 2)

solitaire-solver's People

Contributors

depth221 avatar

Watchers

 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.