Puzzles/PrimeTime

From J Wiki
Jump to: navigation, search

Problem

Provide a J phrase to determine all the times whose display on a 24-hour clock is a prime number.

Constraints

The usual metrics apply: brevity, novelty, velocity and parsimony. ||<tablewidth="100%" style="text-align: center; border: 0 none black;" <b Spoiler Alert!</b

[1]|| ||<style="text-align: center; border: 0 none black;" <small xkcd.com|| <<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR

<<BR


</small

Solutions

No. Phrase #@;: # 100&(6!:2) (7!:2) Notes Author/Sig
0 1 1j1 1 1#!.':'"1'r<0>2.'8!:2(#~1 p:100#.])(#:,@i.)24 60 26 56 0.000338163 44608 HH':MM -- Dan Bron <<DateTime(2007-11-29T21:13:47Z)>>
1 1 1j1 1 1j1 1 1#!.':'"1'r<0>2.'8!:2(#~1 p:100#.])(#:,@i.)24 60 60 26 65 0.0262146 2625728 HH':MM':SS -- Dan Bron <<DateTime(2007-11-29T21:13:47Z)>>
2 }:"1'q(:)r(0)3.'8!:2(#~1 p:100&#.)>,{i.&.>24 60 23 47 -- B Jonas <<DateTime(2007-12-04T08:28:41Z)>>
3 }:"1'q(:)r(0)3.'8!:2(#~1 p:100&#.)>,{i.&.>24 60 60 23 50 with seconds -- B Jonas <<DateTime(2007-12-04T08:55:26Z)>>
4 ,&.:(':'&,"1)"2]2 2$"1}.@":@>1e4+(#~1&p:)100#.>,{i.&.>24 60 39 59 -- B Jonas <<DateTime(2007-12-04T09:16:01Z)>>
5 ,&.:(':'&,"2)"3":@>10 10#:(#~1 p:100&#.)>,{i.&.>24 60 32 53 -- B Jonas <<DateTime(2007-12-04T09:22:27Z)>>
,.(#~1&p:*.60>100&|)i.2400 16 26 1.8e_4 38848 Just the numbers -- Raul Miller <<DateTime(2007-12-21T22:11:36Z)>>

Notes

1. Changed table header from "Verb" to "Phrase". -- B Jonas <<DateTime(2007-12-04T08:28:41Z)>>