0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

中古ノート、買ってみた。 その87

Posted at

概要

中古ノート買ってみた。
wsl1のubuntu18.04にgforth入れてみた。
チュートリアルを作ってみた。

TUTORIAL 15

じゃんけん

Gforth 0.7.3, Copyright (C) 1995-2008 Free Software Foundation, Inc.
Gforth comes with ABSOLUTELY NO WARRANTY; for details type `license'
Type `bye' to exit
require random.fs  ok
variable v  ok
variable t  ok
: janken key 48 - t ! 3 random case 0 of t @ 0 = if ." gu gu aiko" endif t @ 1 = if ." choki gu make" endif t @ 2 = if ." pa gu kati" endif endof 1 of t @ 0 = if ." gu choki kati" endif t @ 1 = if ." choki choki aiko" endif t @ 2 = if ." pa chpki make " endif endof 2 of t @ 0 = if ." gu pa make" endif t @ 1 = if ." choki pa kati" endif t @ 2 = if ." pa pa aiko" endif endof endcase ;  ok
janken gu gu aiko ok
janken choki gu make ok
janken pa gu kati ok
bye

以上。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?