sealrochinha
Programmer
Hi pll!
I start today learn prolog, and I need your help.
I have this:
"There are three types of emissions: alpha, beta and gamma."
"If there is an alpha and beta emissions, then a proton was detected."
"If there is an emission gamma, then a proton was detected."
I have to translate this for prolog.
I tried this, but it´s wrong:
emission(alfa).
emission(beta).
emission(gama).
detected(X) :- emission(alfa), emission(beta).
detected(X) :- emission(gama).
Sorry for my bad english.
I start today learn prolog, and I need your help.
I have this:
"There are three types of emissions: alpha, beta and gamma."
"If there is an alpha and beta emissions, then a proton was detected."
"If there is an emission gamma, then a proton was detected."
I have to translate this for prolog.
I tried this, but it´s wrong:
emission(alfa).
emission(beta).
emission(gama).
detected(X) :- emission(alfa), emission(beta).
detected(X) :- emission(gama).
Sorry for my bad english.