Re: PROLOG
On 5=A4=EB24=A4=E9, =A4W=A4=C810=AE=C944=A4=C0, ntouckcm....@ptt.cc (=AA=BE=
=A8=AC=B1`=BC=D6) wrote:
>
> process(Input, G, P, G, P,_):-
> Input \=3D positive(_),
> Input \=3D negative(_),
> write("Enter either positive(Instance) or negative(Instance) "), =
nl
>
> % The following predicate definitions are duplicated in either
> % the general to specific searches or the specific to genearal searches.
> %
> specialize_set([], [], _, _).
> ERROR: c:/candidate1.pl:54:0: Syntax error: Operator expected
=B3o=B8=CC=AA`=B7N=ABe=AD=B1=A4@=AD=D3=A6=A1=A4l=AA=BA=A7=C0=BA=DD=A1A=A7A=
=A7=D1=A4F=A5[=A5y=B8=B9=A1C
GNU Prolog =AA=BA=B0T=AE=A7=A4=F1=B8=FB=A9=FA=A5=D5=A1A=A5=A6=BB=A1 candida=
te1.pl:54:1: syntax error: . or operator
expected after expression
=B1=B5=A4U=A8=D3=AA=BA......
> specialize_set([Hypothesis|Rest],[Hypothesis|Updated_rest],Instance, Type=
s):-
> not (covers(Hypothesis, Instance)),
> specialize_set(Rest,Updated_rest, Instance, Types).
=B3o=B8=CC=A4=A3=BE=E5=B1o=A7A=A6=B3=A8S=A6=B3=B9J=A8=EC=B0=DD=C3D=A1H GNU =
Prolog =BB=A1=B3o=F9=D8 not (covers(Hypothesis, Instance)) =AA=BA=B2=C4 12
=AD=D3=B2=C5=B8=B9=A6=B3=A6P=BC=CB=AA=BA=BF=F9=BB~=B0T=AE=A7=A1C
=B2=C4 12 =AD=D3=A6=EC=B8m=AB=EA=A6n=ACO not =A4=A7=AB=E1=AA=BA=A8=BA=AD=D3=
=AA=C5=AE=E6=A1C=A7=E2=AA=C5=AE=E6=A7R=B1=BC=B4N=A8S=A6=B3=A8=BA=AD=D3=B0T=
=AE=A7=A4F=A1C
討論串 (同標題文章)
完整討論串 (本文為第 1 之 2 篇):