処理系にはSWI-Prologを用いました.ダウンロードは↓から.
SWI-Prolog's home
入門はこちら.
M.Hiroi's Home Page / Prolog Programming
事実,規則:
fly(X) :- airplane(X).
airplane(jet_plane).
airplane(helicopter).
質問:
?- fly(jet_plane).
YES
?- fly(taro).
NO
こんな感じ.
時間がある時に適当に記事を書く予定です.
fly(X) :- airplane(X).
airplane(jet_plane).
airplane(helicopter).
?- fly(jet_plane).
YES
?- fly(taro).
NO
SRM | Easy | Normal | Hard |
295 | o | - | - |
296 | o | - | - |
297 | o | - | - |
298 | o | - | - |
350 | o | - | - |
386 | o | - | - |
447 | o | - | - |
451 | o | - | - |
462 | o | - | - |
463 | o | - | - |
464 | o | - | - |
465 | o | - | - |
466 | o | - | - |
469 | o | - | - |
471 | o | - | - |
472 | o | - | - |
473 | o | - | - |
474 | o | - | - |
475 | o | - | - |
476 | o | - | - |
477 | o | - | - |
478 | o | - | - |
479 | o | - | - |
480 | o | - | - |
481 | o | - | - |
482 | o | o | - |
483 | o | - | - |
484 | o | - | - |
485 | o | - | - |
486 | o | - | - |
487 | o | - | - |
503 | - | o | - |
511 | - | o | - |
1 | hello world | 30B |
2 | echo | 31B |
3 | 99 shinichiroes of hamaji | 258B |
4 | example com | 451B |
5 | Smileys Triangle | 63B |
8 | delete blank lines | 37B |
14 | ultimate problem | 19B |
16 | even lines | 40B |
19 | Fibonacci Numbers | 46B |
34 | FizzBuzz | 84B |
48 | 67B |
0 件のコメント:
コメントを投稿