Giter Club home page Giter Club logo

xwrd's Introduction

クロスワードパズル

6×6の36マスの中にひらがなを入力し、言葉を作成する。

実施環境

  • Windows WSL Ubuntu 20.04 LTS
  • 文字コード UTF-8
  • gcc (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0
  • GNU Make 4.2.1

コンパイルとクロスワードパズルの実施

make all
./out/all

目標

C言語でクロスワードパズルを作成し、構造体やポインタ、Enum型の使用方法について復習する。

要求事項

  1. 6 * 6 の四角の空欄に文字を入力する
  2. 縦のヒント・横のヒントが表示される
  3. 番号ごとに文字を入力
  4. 入力した文字を反映
  5. すべて入力したら提出
  6. 正解だったらOK
  7. そうでなければもう一度書く

機能要件

  • 6 * 6 の表の表示
  • ヒント番号とヒント内容の表示
  • 入力したい番号を入力する
    • 入力後、ひらがなを入力する
    • 入力した文字を反映する
  • 次に入力したいヒント番号を入力し、同様にして文字を埋めていく
  • クロスワードパズルの表を提出する
    • すべてあっていれば、「Great!」と出力
    • 50%以上あっていれば、Good!
    • 50% 以下であれば Not so good

入力情報

hint.dat

ヒント情報を記載しているファイル。
半角スペースで区切って一行ごとに一つのヒント情報を記載する。

要素番号、向き、ヒント情報のx座標、ヒント情報のy座標、正解文字列の長さ、ヒント情報の内容  

例:
6 よこ 3 3 4 学校の行事。○○○祭で広島焼を作る。

init.dat

クロスワードパズルの初期情報を記載したファイル。hint.datファイルのヒント情報の座標が一致しなければならない。

例:
1*2*34
5・・・*・
・*6・7・
・*・*・*
*8・・・・
9・**・*

  • ヒント番号は指定された座標に記載する
  • 中点(・)は空白を示す。
  • アスタリスク(*)は文字が入力されない区域である。

seikai.dat

クロスワードパズルの正解情報を記載したファイル。

例:
と*き*かぎ
しひよう*か
み*うんえい
ち*た*い*
*ろくじゆう
さん**う*

xwrd's People

Contributors

isamisogabe avatar

Watchers

James Cloos avatar  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.