[Question]
  [
Today while playing with my kids I noticed that an apparently simple toy in the park hid a challenge. 
[![Clock](https://i.stack.imgur.com/dl1Eu.jpg)](https://i.stack.imgur.com/dl1Eu.jpg)
The wheel has a triangle that points to a number, but also has three circles that point to the numbers every 90 degrees from the first one. So:
**Challenge (really simple)**
Given an integer between 1 and 12 (the one pointed by the triangle) in any acceptable form, output also in any acceptable form and order the three numbers pointed by the circles (the ones every 90 degrees).
**Test cases**
```
In       Out
1        4, 7, 10
2        5, 8, 11
3        6, 9, 12
4        7, 10, 1
5        8, 11, 2
6        9, 12, 3
7        10, 1, 4
8        11, 2, 5
9        12, 3, 6
10       1, 4, 7
11       2, 5, 8
12       3, 6, 9
```
This is [code-golf](/questions/tagged/code-golf "show questions tagged 'code-golf'"), so may the shortest code for every language win!
  
[Answer]
# [Python 3](https://docs.python.org/3/), 33 bytes
```
lambda n:{*range(n%3,13,3)}-{n,0}
```
[Try it online!](https://tio.run/##K6gsycjPM/6fZhvzPycxNyklUSHPqlqrKDEvPVUjT9VYx9BYx1izVrc6T8eg9n9afpFCnkJmngJE3hAoq2lVUJSZV6KRp6OQppGnqfkfAA "Python 3 – Try It Online")
---
# [Python 2](https://docs.python.org/2/), 35 bytes
```
lambda n:[(n+c)%12+1for c in 2,5,8]
```
[Try it online!](https://tio.run/##K6gsycjPM/qfZhvzPycxNyklUSHPKlojTztZU9XQSNswLb9IIVkhM0/BSMdUxyL2P4ifB@IXJealp2oY6hgaa1oVFGXmlSjk6SikaeRp/gcA "Python 2 – Try It Online")
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), 8 [bytes](https://github.com/DennisMitchell/jelly/wiki/Code-page)
```
12Rṙ’m3Ḋ
```
A monadic link taking a number and returning a list of numbers.
**[Try it online!](https://tio.run/##y0rNyan8/9/QKOjhzpmPGmbmGj/c0fUfJAAA "Jelly – Try It Online")** or see [all cases](https://tio.run/##y0rNyan8/9/QKOjhzpmPGmbmGj/c0QXiHt1zuP1R05qjkx7unAGkDQ4tA5LeQBz5HwA "Jelly – Try It Online").
### How?
```
12Rṙ’m3Ḋ - Link: number, n   e.g. 5
12       - literal twelve         12
  R      - range                  [1,2,3,4,5,6,7,8,9,10,11,12]
    ’    - decrement n            4
   ṙ     - rotate left            [5,6,7,8,9,10,11,12,1,2,3,4]
      3  - literal three          3
     m   - modulo slice           [5,8,11,2]
       Ḋ - dequeue                [8,11,2]
```
[Answer]
# [Python 2](https://docs.python.org/2/), 35 bytes
```
lambda n:(range(1,13)*2)[n+2:n+9:3]
```
[Try it online!](https://tio.run/##K6gsycjPM/qfZhvzPycxNyklUSHPSqMoMS89VcNQx9BYU8tIMzpP28gqT9vSyjj2f1p@kUKmQmaeAkyJAlCNFZdCQVFmXolGmkampuZ/AA "Python 2 – Try It Online")
[Answer]
# [MATL](https://github.com/lmendo/MATL), 9 bytes
```
I:I*+12X\
```
[**Try it online!**](https://tio.run/##y00syfn/39PKU0vb0Cgi5v9/EwA "MATL – Try It Online")
### Explanation
Consider input `4` as an exmaple.
```
I:     % Push [1 2 3]
       % STACK: [1 2 3]
I      % Push 3
       % STACK: [1 2 3], 3
*      % Multiply, element-wise
       % STACK: [3 6 9]
+      % Add implicit input, element-wise
       % STACK: [7 10 13]
12     % Push 12
X\     % 1-based modulus. Implicit display
       % STACK: [7 10 1]
```
[Answer]
# [R](https://www.r-project.org), ~~29~~ 28 bytes
*Thanks to @Giuseppe for saving a byte!*
```
function(n)(n+1:3*3-1)%%12+1
```
[Try it online!](https://tio.run/##K/qfZvs/rTQvuSQzP08jT1MjT9vQyljLWNdQU1XV0Ejb8H9afpGCRqZCZp6CoZWhkSZXNZcCECQnlmikaWRqasJ5SjF5Sppctf8B)
[Answer]
# APL+WIN, 13bytes
```
(⎕⌽⍳12)[3×⍳3]
```
Explanation:
```
⎕ Prompt for screen input of indicated time t
⍳12 Create a vector of integers from 1 to 12
⌽ Rotate the vector by t elements front to back
[3×⍳3] Select 3rd, 6th and 9th elements.
```
[Answer]
# [C (gcc)](https://gcc.gnu.org), 48 bytes
```
i;f(n){for(i=4;--i;printf("%d ",n%12?:12))n+=3;}
```
[Try it online!](https://tio.run/##RY7BCsIwEETv@YolUNgl5pDWU9fQb5FIJAfXUuup5NtjUsXObebtDBvsPYRSEkcU2uJzweTPbG3ieUmyRtTdDfRJOtdPo@uJxPiBc6kMHtckSGpTUFWrgC0V7xjk4gYGY4R2@D1pOlbHOgtC/Eftg8PN7/WFWv@SrHL5AA)
[Answer]
# JavaScript (ES6), 29 bytes
Similar to [xnor's answer](https://codegolf.stackexchange.com/a/152118/58563).
```
n=>[2,5,8].map(k=>(n+k)%12+1)
```
### Demo
```
let f =
n=>[2,5,8].map(k=>(n+k)%12+1)
for(n = 1; n <= 12; n++) {
  console.log(n + ' -> ' + f(n));
}
```
[Answer]
# [Octave](https://www.gnu.org/software/octave/), 25 bytes
```
@(x)[a=1:12 a](3+x:3:9+x)
```
[Try it online!](https://tio.run/##Lc47CsMwEEXR3qt4TUDGg/FI/goM2UdIIULcpgnBu1fm42Kaw1x4n9e3/N712Pu@r/dwto@yc@aI8gypO3PKW3e29QiMFrhhJCwEHpojRJeJsIqwSHKZCZtIFBldLJETmVwsIejP7GIJIYksLpYQRpH1Ek0Ik8h2iSaEWYQHF7KRCmyggWxUiAb6LxOb@gc "Octave – Try It Online")
Fairly simple anonymous function.
We first create an array of `[1:12 1:12]` - so two copies of the full number set. Then we index in to select the values of `x+3, x+6, x+9`, where `x` is the number input. 
Octave is 1-indexed, so we can simply select the array elements based on the input (although to be honest 0-indexed would use the same number of bytes here).
This seems to use a method that is unique to the other answers in that by having two copies of the array, we don't have to wrap the indices using modulo.
[Answer]
# Befunge-93, ~~20~~ ~~19~~ 18 bytes
```
852<_@#:.+1%+66+&p
```
[Try it online!](http://befunge.tryitonline.net/#code=ODUyPF9AIzouKzElKzY2KyZw&input=Ng)
**Explanation**
```
852                   Push 8, 5 and 2 onto the stack - the offsets we're going to add.
   <                  Reverse direction, and start the main loop.
852                   Push 2, 5, and 8 onto the stack, but we don't actually want these.
                 p    So we use a "put" operation to drop the top three values.
                &     Read the hour from stdin.
               +      Add it to the topmost offset.
         +1%+66       Mod 12 and add 1 to get it in the range 1 to 12.
        .             Then output the result to stdout.
    _@#:              Exit if the next offset is zero (i.e. nothing more on the stack).
   <                  Otherwise start the main loop again. 
```
This relies on behaviour specific to the reference interpreter: on end-of-file, the `&` operator returns the last value that was read. That's why we can safely re-read the hour from stdin on each iteration of the loop.
[Answer]
# [APL (Dyalog)](https://www.dyalog.com/), 12 bytes
```
1+12|2 5 8∘+
```
[Try it online!](https://tio.run/##ATcAyP9hcGwtZHlhbG9n//9m4oaQMSsxMnwyIDUgOOKImCv//@KNqijiiqIsJ@KGkicsZinCqOKNszEy "APL (Dyalog Unicode) – Try It Online")
[Answer]
# [05AB1E](https://github.com/Adriandmen/05AB1E), 8 bytes
```
ƵžS+12%>
```
At the time of writing this, this submission has the lowest score submitted. Technically I am winning!
[Try it online!](https://tio.run/##yy9OTMpM/f//2Naj@4K1DY1U7f7/NwEA)
# How?
```
ƵžS                   # Push the list [2, 5, 8]
   +                  # Add the input to each number
    12%               # Mod each result by 12
       >              # Increment each
                      # And print the ending list implicitly!
```
See [this tip of Kevin](https://codegolf.stackexchange.com/a/166851/98140) to know why `Ƶž` is 258!
[Answer]
# [SOGL V0.12](https://github.com/dzaima/SOGLOnline), 9 [bytes](https://github.com/dzaima/SOGL/blob/master/chartable.md)
```
3{3+:6«‰P
```
[Try it Here!](https://dzaima.github.io/SOGLOnline/?code=MyU3QjMrJTNBNiVBQiV1MjAzMFA_,inputs=OQ__,v=0.12)
[Answer]
# [Clean](https://clean.cs.ru.nl), 44 bytes
```
import StdEnv
@n=[(n+i)rem 12+1\\i<-[2,5,8]]
```
[Try it online!](https://tio.run/##S85JTcz7n5ufUpqTqpCbmJn3PzO3IL@oRCG4JMU1r4zLIc82WiNPO1OzKDVXwdBI2zAmJtNGN9pIx1THIjb2f3BJIlCtrYKDguH/f8lpOYnpxf91PX3@u1TmJeZmJhcDAA "Clean – Try It Online")
[Answer]
# [C# (.NET Core)](https://www.microsoft.com/net/core/platform), 42 bytes
```
h=>new[]{(2+h)%12+1,(5+h)%12+1,(8+h)%12+1}
```
[Try it online!](https://tio.run/##RY3BisIwEIbPyVMM4kJKq9jCglDtRfCkILjgofQQstEOaAJJVCTk2euwrMrA/N/hn2@Unyjr9HD1aE6wf/igLzVXZ@k97CL3QQZUsL4atUATCqDVdg384EXvezwGWMLQLxuj720XRZX32VdZ5WUhvj84f2Eaav5S3iz@wlaiERmPnB2tA0FyQDKWNcWCsiLI84wzarCbdCCdkw9qvP8LzMjJ2Moab896enAY9AaNFuNRxASTBuLfUTvrUvGP5QerLo3IwBKnGZ4 "C# (.NET Core) – Try It Online")
Essentially just a port of many of the other answers to C#.
[Answer]
# Japt, 11 bytes
```
3ÆU±3 uC ªC
```
[Try it](https://ethproductions.github.io/japt/?v=1.4.5&code=M8ZVsTMgdUMgqkM=&input=OA==)
---
## Explanation
Implicit input of integer `U`. Generate a 3 element array (`3Æ`) and, for each element, increment `U` by 3 (`U±3`), modulo by 12 (`uC`) and, because `12%12=0`, return the result OR 12 (`ªC`).
[Answer]
# [K (oK)](https://github.com/JohnEarnest/ok), 11 bytes
**Solution:**
```
1+12!2 5 8+
```
[Try it online!](https://tio.run/##y9bNz/7/31Db0EjRSMFUwULb8P9/AA "K (oK) – Try It Online")
**Examples:**
```
1+12!2 5 8+1
4 7 10
1+12!2 5 8+2
5 8 11
1+12!2 5 8+3
6 9 12
1+12!2 5 8+4
7 10 1
```
**Explanation:**
This was the first solution that came to mind. Might not be the best or shortest.
```
1+12!2 5 8+ / the solution
     2 5 8+ / add 2, 5 and 8 to the input
  12!       / apply modulo 12 to the results
1+          / add 1
```
[Answer]
# GolfScript, 46 bytes
```
~13,1>:x?:y;0:i;x y 3+12%=x y 6+12%=x y 9+12%=
```
This is the first time I'm doing code golf, so with my lack of experience I've probably not found the best solution, but I need to start somewhere, right?
[Try it online](https://copy.sh/golfscript/?c=IjEifjEzLDE+Ong/Onk7MDppO3ggeSAzKzEyJT14IHkgNisxMiU9eCB5IDkrMTIlPQ==) or [try all cases](https://copy.sh/golfscript/?c=IjEifjEzLDE+Ong/Onk7MDppO3ggeSAzKzEyJT14IHkgNisxMiU9eCB5IDkrMTIlPScnCiIyIn4xMywxPjp4Pzp5OzA6aTt4IHkgMysxMiU9eCB5IDYrMTIlPXggeSA5KzEyJT0nJwoiMyJ+MTMsMT46eD86eTswOmk7eCB5IDMrMTIlPXggeSA2KzEyJT14IHkgOSsxMiU9JycKIjQifjEzLDE+Ong/Onk7MDppO3ggeSAzKzEyJT14IHkgNisxMiU9eCB5IDkrMTIlPScnCiI1In4xMywxPjp4Pzp5OzA6aTt4IHkgMysxMiU9eCB5IDYrMTIlPXggeSA5KzEyJT0nJwoiNiJ+MTMsMT46eD86eTswOmk7eCB5IDMrMTIlPXggeSA2KzEyJT14IHkgOSsxMiU9JycKIjcifjEzLDE+Ong/Onk7MDppO3ggeSAzKzEyJT14IHkgNisxMiU9eCB5IDkrMTIlPScnCiI4In4xMywxPjp4Pzp5OzA6aTt4IHkgMysxMiU9eCB5IDYrMTIlPXggeSA5KzEyJT0nJwoiOSJ+MTMsMT46eD86eTswOmk7eCB5IDMrMTIlPXggeSA2KzEyJT14IHkgOSsxMiU9JycKIjEwIn4xMywxPjp4Pzp5OzA6aTt4IHkgMysxMiU9eCB5IDYrMTIlPXggeSA5KzEyJT0nJwoiMTEifjEzLDE+Ong/Onk7MDppO3ggeSAzKzEyJT14IHkgNisxMiU9eCB5IDkrMTIlPScnCiIxMiJ+MTMsMT46eD86eTswOmk7eCB5IDMrMTIlPXggeSA2KzEyJT14IHkgOSsxMiU9Jyc=)
[Answer]
# [Brain-Flak](https://github.com/DJMcMayhem/Brain-Flak), 84 bytes
```
(()()()){({}<(()(){})(((()()()){}){}<>){(({})){({}[()])<>}{}}<>(([{}]{})<>)>[()])}<>
```
[Try it online!](https://tio.run/##SypKzMzTTctJzP7/X0NDEwQ1qzWqa23AnOpaTQ0NuHAtENnYAaWB8hBV0RqasZo2drXVtUAJDY3o6tpYoBRQjR1YBij4/78JAA "Brain-Flak – Try It Online")
At least I beat [Doorknob's face solution](https://codegolf.stackexchange.com/a/152240/31203)...
Explanation:
```
LOOP 3 TIMES: (()()()){({}<
  n += 2:
   (()(){})
  push 12:
   (((()()()){}){}<>)
  n mod 12 + 1; pushing to both stacks:
   {(({})){({}[()])<>}{}}<>(([{}]{})<>)
END LOOP: >[()])}<>
```
[Answer]
# [Pyth](https://github.com/isaacg1/pyth), 12 bytes
```
%R12+LQ*R3S3    
```
[Try it online!](https://tio.run/##K6gsyfj/XzXI0EjbJ1AryDjY@P9/EwA "Pyth – Try It Online")
[Answer]
# Wolfram Language (Mathematica) 20 bytes
```
Mod[#+{3,6,9},12,1]&
```
The normal modulus operation, threaded over a list, offset by 1.
[Try it online!](https://tio.run/##y00syUjNTSzJTE78n2b73zc/JVpZu9pYx0zHslbH0EjHMFbtv0t@NFdAUWZeSXSmjoKSgq6dgpKOQlp0Zmwsl45CNVDMEIiMamP/AwA)
[Answer]
# [Vyxal](https://github.com/Vyxal/Vyxal), 8 bytes
```
⁺ẇf+12%›
```
[Try it online!](https://vyxal.pythonanywhere.com/#WyIiLCIiLCLigbrhuodmKzEyJeKAuiIsIiIsIjQiXQ==) ([All test cases](https://vyxal.pythonanywhere.com/#WyIiLCIxMsm+xpsiLCLigbrhuodmKzEyJeKAuiIsIm4kd0o74oGLIiwiIl0=))
Port of [SunnyMoon's 05AB1E solution](https://codegolf.stackexchange.com/a/215712/80050)
**How it works:**
```
⁺ẇf+12%›
⁺ẇ        The number 258
  f       ...as a list of digits ⟨ 2 | 5 | 8 ⟩
   +      Add the input to each
    12%   Mod-12 each
       ›  Increment each
          (implicit output)
```
[Answer]
# [Thunno 2](https://github.com/Thunno/Thunno2), 8 [bytes](https://github.com/Thunno/Thunno2/blob/main/docs/codepage.md)
```
ṇɗd+12%⁺
```
[Try it online!](https://Not-Thonnu.github.io/run#aGVhZGVyPSZjb2RlPSVFMSVCOSU4NyVDOSU5N2QlMkIxMiUyNSVFMiU4MSVCQSZmb290ZXI9JmlucHV0PTcmZmxhZ3M9)
#### Explanation
```
ṇɗd+12%⁺  # Implicit input
ṇɗ        # Push compressed integer 258
  d+      # Add [2,5,8] to input
    12%   # Mod each by 12
       ⁺  # Increment each
          # Implicit output
```
[Answer]
# [Nekomata](https://github.com/AlephAlpha/Nekomata), 9 bytes
```
12Rᶠ{-Z3¦
```
[Attempt This Online!](https://ato.pxeger.com/run?1=m70iLzU7PzexJHFZtJJurlLsgqWlJWm6FmsMjYIebltQrRtlfGjZkuKk5GKoxIJdhlxGXMZcJlymXGZc5lwWXJZchgZchoZchkYQFQA)
```
12Rᶠ{-Z3¦
12R         [1,2,...,12]
   ᶠ{       Filter by
     -          Subtract the input
      Z         Check if the result is non-zero
       3¦       Check if the result is divisible by 3
```
---
# [Nekomata](https://github.com/AlephAlpha/Nekomata), 10 bytes
```
258¢D+12%→
```
[Attempt This Online!](https://ato.pxeger.com/run?1=m70iLzU7PzexJHFZtJJurlLsgqWlJWm6FmuNTC0OLXLRNjRSfdQ2aUlxUnIxVGbBLkMuIy5jLhMuUy4zLnMuCy5LLkMDLkNDLkMjiAoA)
```
258¢D+12%→
258¢D       Decimal digits of 258
     +      Add
      12%   Modulo 12
         →  Increment
```
[Answer]
# [Piet](https://www.dangermouse.net/esoteric/piet.html) + [ascii-piet](https://github.com/dloscutoff/ascii-piet), 45 bytes (5×18=90 codels)
```
tAaaqreeumccsqqqijlVa rbiqaaueljnvea?_ t?B tt
```
[Try Piet online!](https://piet.bubbler.one/#eJyVj1EKgzAQRO-y3yNkNYnGq6gfxaYgWCvYfknv3l27HsBk4G02M0uy0_i6Z2q7zoEjOF3SgE5DER4luFYFMIODqpK2bnZoIDZzJ_UeXY9_OmgwikkmHGOk24g0kOCOg7_2Ko25a38ZQFteqaWiKAg0T0-p2cmSU95Gah-3ecugaVk_b73rF7H2S2msjN4YjNFYGxtjMrI7i3Mil_T9AV0UXkY)
![](https://github.com/Bubbler-4/svg-stuff-and-tools/raw/47ae5ea89ef286f7aab2e4d517a06c3dd5363575/images/CodeGolfSE/152114.svg)
My looping template is getting weirder and weirder... :P
```
inN 4    [n 4]; force toggle CC at the exit of 4 region
Loop:
  dup CC+    [n flag] switch CC on 3rd iteration so it will exit after the loop
  2 1 roll   [flag n]
  2 +        [flag n+2]
  3 dup dup * + %  [flag (n+2)%12]
  1 + d outN [flag next_n] compute and print the next number
  1 outC     [flag next_n] print the separator (ASCII 1)
  2 1 roll   [next_n flag]
  2 /        [next_n flag/2] divide flag by 2; flag becomes odd after two loops
```
[Answer]
# [Piet](https://www.dangermouse.net/esoteric/piet.html) + [ascii-piet](https://github.com/dloscutoff/ascii-piet), 62 bytes (46×2=92 codels)
```
TABdDTvVvVnNNFJAQUiIiIIAeEeEuUUMTJBCSBvVvVNMLnNnNfFFVBQIMEiCcc
```
[Try Piet online!](https://piet.bubbler.one/#eJxdj8EOwiAMht-l55LQMYbyKoSDmZgsmbpkejJ7dxspDsahP7Tla_8PjM9rAh-CRjpHDDSI9qIdUsdaykj_6ND9Yi6YrKcWIxQrWabogzZDGeYqtWirz5RVt4PKntJlDulm34YjM4sLJyZMZYZaWL-7qEHk9ryVVWyMCGtawINSChDm6c530nz4ldYR_O0yrwlheizvF9cG2L7PpGCu)
[Answer]
# [Pushy](https://github.com/FTcode/Pushy), 12 bytes
```
258s{K+12%h_
```
**[Try it online!](https://tio.run/##Kygtzqj8/9/I1KK42lvb0Eg1I/7///@GhgA "Pushy – Try It Online")**
```
258            \ Push 258                            
   s           \ Split into digits, yielding [2, 5, 8]
    {K+        \ Add input to each
       12%     \ Modulo each by 12
          h    \ Increment each
           _   \ Print (space separated)
```
## 12 bytes
An alternative for the same byte count:
```
12R{:{;$...#
```
**[Try it online!](https://tio.run/##Kygtzqj8/9/QKKjaqtpaRU9PT/k/kAsA "Pushy – Try It Online")**
```
12R            \ Push range(1, 12), inclusive
   {: ;        \ Input times do:
     {         \   Rotate left
       $       \ While there are items on stack:
        ...    \   Pop the top three
           #   \   Print top item
```
[Answer]
# [Haskell](https://www.haskell.org/), 29 bytes
*-2 bytes thanks to Laikoni.*
```
f n=[mod(n+i)12+1|i<-[2,5,8]]
```
[Try it online!](https://tio.run/##y0gszk7Nyfn/P00hzzY6Nz9FI087U9PQSNuwJtNGN9pIx1THIjb2f25iZp6CrUJuYoGvgkZBUWZeiYKeQpqmQrShnp6hUex/AA "Haskell – Try It Online")
Not very original, no...
[Answer]
# [Swift](https://swift.org), 30 bytes
```
{n in[2,5,8].map{($0+n)%12+1}}
```
[Try it online!](https://tio.run/##Ky7PTCsx@Z@TWqKQpmD7vzpPITMv2kjHVMciVi83saBaQ8VAO09T1dBI27C29n9afpFCJlCFgqGenp6hUXVBUWZeiUamTppGpqZm7X8A)
Port of many other answers to Swift
[Answer]
# Wolfram Language (Mathematica) 35 bytes
```
Range@12~RotateLeft~#~Take~{3,9,3}&
```
The above asserts, in infix notation, what can be expressed more clearly as
```
Function[Take[RotateLeft[Range[12],Slot[1]],List[3,9,3]]]
```
`RotateLeft` rotates `Range[12]`, the sequence 1,2,...12, leftward by the input number. `Slot[1]` or `#` holds the input number, n.
For example, with n = 4,
```
Function[RotateLeft[Range[12],4]]]
```
returns the list
```
{5, 6, 7, 8, 9, 10, 11, 12, 1, 2, 3, 4}
```
`Take...{3,9,3}` returns every third element in that list from position 3 through position 9, namely
```
{7, 10, 1}
```
]