re: Daily Challenge #75 - Set Alarm VIEW POST

FULL DISCUSSION
 

How about prolog?
A file with one fact should do it...

setAlarm(true,false).

To run..

> gprolog --consult-file setAlarm.pl
GNU Prolog 1.4.5 (64 bits)
Compiled Aug 20 2018, 15:27:00 with clang
By Daniel Diaz
Copyright (C) 1999-2018 Daniel Diaz
compiling /Users/Will/setAlarm.pl for byte code...
/Users/Will/setAlarm.pl compiled, 1 lines read - 257 bytes written, 4 ms
| ?- setAlarm(false,false).

no
| ?- setAlarm(false,true).

no
| ?- setAlarm(true,false).

yes
| ?- setAlarm(true,true).

no
 

Prolog still scares me . . . not its syntax, but seemingly untapped potential.

code of conduct - report abuse