-
Notifications
You must be signed in to change notification settings - Fork 0
/
22 10 23.pl
96 lines (81 loc) · 2.26 KB
/
22 10 23.pl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
% 22 10 23
% 35 algs v over
/*
algs
medicine prob and sol
sim's medit, medic, tt have enough As
*/
:-include('../listprologinterpreter/listprolog.pl').
:-include('../Text-to-Breasonings/text_to_breasonings.pl').
%:-include('21 10 23.pl').
/*
?- qa_tt3(1).
*** Journey 1 ***
Have you meditated before time travel?
(y/n)?
|: y
You may now time travel.
Have you time travelled?
(y/n)?
|: y
You may now meditate.
Have you meditated?
(y/n)?
|: y
Good
true.
*/
qa_tt([*,meditation_As],_).
qa_tt("Have you meditated before time travel?","You may now time travel.").
qa_tt([*,meditation_As],_).
qa_tt([*,time_travel_As],_).
qa_tt("Have you time travelled?","You may now meditate.").
qa_tt("Have you meditated?","Good").
qa_tt([*,medicine_problems_and_solutions],_).
qa_tt([*,immortality_medicine],_).
qa_tt1 :-
findall(_,(qa_tt(Q,A),(Q=[*,P]->P;(writeln(Q),writeln("(y/n)?"),read_string(user_input,"\n\r","\n\r",_,S),
(S="y"->writeln(A);abort)))),_),!.
qa_tt3(Journeys) :-
numbers(Journeys,1,[],JN),
%length(JL,Journeys),
findall(_,(member(JN1,JN),write("*** Journey "),write(JN1),writeln(" ***"),qa_tt1),_),!.
four_by_fifty_As :-
texttobr2_1(64),!.
meditation_As :-
four_by_fifty_As,!.
time_travel_As :-
four_by_fifty_As,!.
immortality_medicine :-
findall(_,(medicine0,four_by_fifty_As),_),!.
medicine_problems_and_solutions :-
findall(_,(medicine0,(problem->four_by_fifty_As;true)),_),!.
problem :-
random(X),X1 is floor(X*2),X1=0.
medicine0 :-
medicine(_),medicine1(_),medicine2(_).
medicine1("A").
medicine1("B").
medicine1("B to B").
medicine2("Immortality").
medicine2("Body replacement").
medicine2("Anti-ageing medicine").
medicine("memory").
medicine("thinking").
medicine("stopping dementia").
medicine("seeing clearly").
medicine("muscle relaxation").
medicine("Circulatory system / Cardiovascular system").
medicine("Digestive system and Excretory system").
medicine("Endocrine system").
medicine("Integumentary system / Exocrine system").
medicine("Immune system and lymphatic system:").
medicine("Muscular system").
medicine("Nervous system").
medicine("Renal system and Urinary system").
medicine("Reproductive system").
medicine("Respiratory system").
medicine("Skeletal System").
medicine("antidepressant").
medicine("antipsychotic").
medicine("Other medicines for the body").