Re: i am a prolog beginner pls help me in getting this



On Apr 18, 1:26 pm, Jussi Piitulainen <jpiit...@xxxxxxxxxxxxxxxx>
wrote:
jaya chandra writes:
Joachim Schimpf wrote:
rams.13...@xxxxxxxxx wrote:

?- everyother([3,4,11,0,9,19],X).

X = [3, 11, 9] ;

No

[snip]

This code gives the answers you want:

everyother([3,4,11,0,9,19],[3, 11, 9]).
...

hey thanku for the help.but it should be written generally means not
only for that numbers but for all the input please help me in the
code pls help

Can you write a solution for lists of length one? Lists of length two?
Lists of length at most two? List of length at most three?

we have to write a program which gives output for the following
examples

.