text:
Havel-to-da-Hakimi
It was a dark and stormy night. Detective Havel and Detective Hakimi arrived at the scene of the crime.
Other than the detectives, there were 10 people present. They asked the first person, "out of the 9 other people here, how many had you already met before tonight?" The person answered "5". They asked the same question of the second person, who answered "3". And so on. The 10 answers they got from the 10 people were:
5 3 0 2 6 2 0 7 2 5

The detectives looked at the answers carefully and deduced that there was an inconsistency, and that somebody must be lying. (For the purpose of this challenge, assume that nobody makes mistakes or forgets, and if X has met Y, that means Y has also met X.)
Your challenge for today is, given a sequence of answers to the question "how many of the others had you met before tonight?", apply the Havel-Hakimi algorithm to determine whether or not it's possible that everyone was telling the truth.
If you're feeling up to it, skip ahead to the Challenge section below. Otherwise, try as many of the optional warmup questions as you want first, before attempting the full challenge.
Optional Warmup 1: eliminating 0's.
Given a sequence of answers, return the same set of answers with all the 0's removed.
warmup1([5, 3, 0, 2, 6, 2, 0, 7, 2, 5]) => [5, 3, 2, 6, 2, 7, 2, 5]
warmup1([4, 0, 0, 1, 3]) => [4, 1, 3]
warmup1([1, 2, 3]) => [1, 2, 3]
warmup1([0, 0, 0]) => []
warmup1([]) => []

If you want to reorder the sequence as you do this, that's fine. For instance, given [4, 0, 0, 1, 3], then you may return [4, 1, 3] or [1, 3, 4] or [4, 3, 1] or any other ordering of these numbers.
Optional Warmup 2: descending sort
Given a sequence of answers, return the sequence sorted in descending order, so that the first number is the largest and the last number is the smallest.
warmup2([5, 1, 3, 4, 2]) => [5, 4, 3, 2, 1]
warmup2([0, 0, 0, 4, 0]) => [4, 0, 0, 0, 0]
warmup2([1]) => [1]
warmup2([]) => []

Optional Warmup 3: length check
Given a number N and a sequence of answers, return true if N is greater than the number of answers (i.e. the length of the sequence), and false if N is less than or equal to the number of answers. For instance, given 7 and [6, 5, 5, 3, 2, 2, 2], you would return false, because 7 is less than or equal to 7.
warmup3(7, [6, 5, 5, 3, 2, 2, 2]) => false
warmup3(5, [5, 5, 5, 5, 5]) => false
warmup3(5, [5, 5, 5, 5]) => true
warmup3(3, [1, 1]) => true
warmup3(1, []) => true
warmup3(0, []) => false

Optional Warmup 4: front elimination
Given a number N and a sequence in descending order, subtract 1 from each of the first N answers in the sequence, and return the result. For instance, given N = 4 and the sequence [5, 4, 3, 2, 1], you would subtract 1 from each of the first 4 answers (5, 4, 3, and 2) to get 4, 3, 2, and 1. The rest of the sequence (1) would not be affected:
warmup4(4, [5, 4, 3, 2, 1]) => [4, 3, 2, 1, 1]
warmup4(11, [14, 13, 13, 13, 12, 10, 8, 8, 7, 7, 6, 6, 4, 4, 2]) => [13, 12, 12, 12, 11, 9, 7, 7, 6, 6, 5, 6, 4, 4, 2]
warmup4(1, [10, 10, 10]) => [9, 10, 10]
warmup4(3, [10, 10, 10]) => [9, 9, 9]
warmup4(1, [1]) => [0]

You may assume that N is greater than 0, and no greater than the length of the sequence. Like in warmup 1, it's okay if you want to reorder the answers in your result.
Challenge: the Havel-Hakimi algorithm
Perform the Havel-Hakimi algorithm on a given sequence of answers. This algorithm will return true if the answers are consistent (i.e. it's possible that everyone is telling the truth) and false if the answers are inconsistent (i.e. someone must be lying):
Remove all 0's from the sequence (i.e. warmup1).
If the sequence is now empty (no elements left), stop and return true.
Sort the sequence in descending order (i.e. warmup2).
Remove the first answer (which is also the largest answer, or tied for the largest) from the sequence and call it N. The sequence is now 1 shorter than it was after the previous step.
If N is greater than the length of this new sequence (i.e. warmup3), stop and return false.
Subtract 1 from each of the first N elements of the new sequence (i.e. warmup4).
Continue from step 1 using the sequence from the previous step.
Eventually you'll either return true in step 2, or false in step 5.
You don't have to follow these steps exactly: as long as you return the right answer, that's fine. Also, if you answered the warmup questions, you may use your warmup solutions to build your challenge solution, but you don't have to.
hh([5, 3, 0, 2, 6, 2, 0, 7, 2, 5]) => false
hh([4, 2, 0, 1, 5, 0]) => false
hh([3, 1, 2, 3, 1, 0]) => true
hh([16, 9, 9, 15, 9, 7, 9, 11, 17, 11, 4, 9, 12, 14, 14, 12, 17, 0, 3, 16]) => true
hh([14, 10, 17, 13, 4, 8, 6, 7, 13, 13, 17, 18, 8, 17, 2, 14, 6, 4, 7, 12]) => true
hh([15, 18, 6, 13, 12, 4, 4, 14, 1, 6, 18, 2, 6, 16, 0, 9, 10, 7, 12, 3]) => false
hh([6, 0, 10, 10, 10, 5, 8, 3, 0, 14, 16, 2, 13, 1, 2, 13, 6, 15, 5, 1]) => false
hh([2, 2, 0]) => false
hh([3, 2, 1]) => false
hh([1, 1]) => true
hh([1]) => false
hh([]) => true

Detailed example
Here's the first pass through the algorithm using the original example:
[5, 3, 0, 2, 6, 2, 0, 7, 2, 5] - Starting sequence
[5, 3, 2, 6, 2, 7, 2, 5] - After step 1, removing 0's.
Step 2: This sequence is not empty, so go on to step 3.
[7, 6, 5, 5, 3, 2, 2, 2] - After step 3, sorting in descending order.
[6, 5, 5, 3, 2, 2, 2] - After step 4, removing the first answer N = 7.
Step 5: N (7) is less than or equal to the number of answers remaining in the sequence (7), so go on to step 6.
[5, 4, 4, 2, 1, 1, 1] - After step 6, subtracting 1 from each of the first 7 answers (which is all of them in this case).
At this point you would start over at step 1 with the sequence [5, 4, 4, 2, 1, 1, 1]. After your second pass through the algorithm, your sequence will be [3, 3, 1, 0, 0, 1], so start back at step 1 with this sequence. After your third pass you'll have [2, 0, 0]. On your fourth pass, you'll stop at step 5, because you'll have N = 2 and an empty sequence ([]), and 2 > 0, so you will return false.
~
Thought this would be fun to golf

Shortest code wins.

-1 for specifying a specific algorithm to get the results, -1 for optional tasks.

@Pavel Note that 0x45 says you don’t have to use this algorithm or do any of the warm up tasks. I thought it was reasonably well specified.

"somebody must be lying" ...or they just don't remember - I'm pretty sure that everyone I've met won't necessarily remember meeting me!

I like the challenge task, but everything about the algorithm and warm-ups seems unnecessary, confusing, and kind-of patronizing. I think it would be better to just say "One method is to remove the biggest number (k), subtract 1 from each of the k next biggest numbers, and repeat this until all numbers are 0 (success) or you get a negative (fail)."

@LuisfelipeDejesusMunoz I'm not OP, but the algorithm as written only removes one of them, as mentioned during the second pass of the example demonstration.

I've VTCed this as unclear as I'm finding it very difficult to cut through all the fluff and actually get to the core of the challenge; I've read through it 4 times and taken at least twice as many stabs at it and am still no closer to understanding it.

Jelly,  23  12 bytes
ṢṚḢ-€+ƊƊƬ>-Ȧ

A monadic Link accepting a list which yields 1 if the answers are consistent otherwise  0.
Try it online! Or see the test-suite.
How?
ṢṚḢ-€+ƊƊƬ>-Ȧ - Link: list of integers
        Ƭ    - collect up while results change:
       Ɗ     -   last three links as a monad i.e. f(L):
Ṣ            -     sort                      [min(L),...,max(L)]
 Ṛ           -     reverse                   [max(L),...,min(L)]
      Ɗ      -     last three links as a monad i.e. f([a,b,c,...,x]):
  Ḣ          -       pop head                          a
   -€        -       -1 for each                       [-1,-1,...,-1] (length a)
     +       -       add (vectorises)                  [b-1,c-1,...,x-1,-1,-1,...]
         >-  - greater than -1? (vectorises)
           Ȧ - Any and all? (0 if empty or contains a 0 when flattened, else 1)

Jelly, 22 bytes
ḟ0ṢṚ0_1x$}ß`ɗL<¥?Ḣ$1L?

Try it online!
A full program that takes the input list of answers as its argument and returns 1 for valid and 0 for impossible.
Thanks to @JonathanAllan for noting an issue with the second version.

@JonathanAllan thanks. The issue is that 1Ŀ only seems to work when there’s more than one link. Using ß on its own didn’t work because it ends up being called as a dyad, and then there are three consecutive dyads in a dyadic chain. In the end I’ve used ß` which seems to work ok.

Ruby, 90 bytes
Forgoes zero-pruning in favor of saving 2 bytes. Who needs that, anyways? Instead, I count how many I've decremented (skipping over zeroes) and if I haven't decremented the current largest number fully, then it's a false.
I really hoped that I could forgo sorting as well but alas, things don't always work as planned...
->a{b=1;(a.sort_by!(&:-@);i=a.shift;a.map!{|e|i>0&&e>0?(i-=1;e-1):e};b&&=i<1)while[]!=a;b}

Try it online!


text:
Random Cake Bake
Warning: This is a bit lengthy
I have decided to build my own random function I call it "Random Cake"
This function should get an integer value between 0 and 99999
Ingredients
 1 x DateTime function
 1 x Sin : Radians
 1 x Absolute Value
 1 x π
 a dash of multiplication, division and addition

Here is the recipe
Recipe

Get Current Date and Time ..... (1)

 "23/05/2019 17:39:42.631"

Break it into milliseconds, seconds, minutes, hours, days, months, and years

Add 1 to the milliseconds ..... (2)

 1 + 631 = 632

Add 1 to the seconds ..... (3)

 1 + 42 = 43

Multiply both results in (2) & (3) and stir ..... (4)

632 * 43 = 27,176

Divide the result from (4) by 360 and then Use the Sin (Rad not degrees) where Sin(π) = 0 and Sin(π/2) = 1 ..... (5)

 27,176 / 360 = 75.48888889
 Sin(75.48888889) in Rad = 0.09054103861

then multiply step 5 result by 1000 ..... (6)

 0.09054103861 * 1000 = 90.54103861

Note this value might be negative, no problem here
Keep this in the fridge until it cools down

In another bowl we add 3 to the Hours and multiply by the minutes .....
  (7)

 (3 + 17) * 39  = 780

Now we add last step's results (7) to the cooled mix in step (6)  .....
  (8)

 780 + 90.54103861 = 870.54103861

We are almost there, be patient

Get the absolute value of step (8) as it could be negative ..... (9)

 Abs(870.54103861) = 870.54103861

and add the flavor of the recipe which is

The first 2 digits (without leading zeroes) in the result of step (9)
  will represent the location of our flavor, which is the 5 digits of π after that position in the decimal representation of π..... (10)

For example:
Here is the value of π: 3.141592653589793238462643383279502884197169399375105820974944592307816406286208998628034825342117067982148086513282306647093844609550582231725359408128481

 Results of step (9) was 870.54103861
 First 2 non zero digits are 87
 So we go to digit number 87 after the decimal point in π for the length of 5 digits
 which is 48253

 if your result was 0.001045678 then your 2 non zero digits are 10
 the point is the number does not start with 0
 so if your number anything like 0.000012345 then plz ignore all initial zeros till you get to the meat > 0

in some languages you get more accurate than the other so I think you have to complete the rest of the digits manually :)
if your language gives you π = 3.14 then you have to add 159265358979323846264338327950288419716939937510582097494459230... to it

Add the number in step (10) to the result in step (9) ..... (11)

 48253 + 870.54103861 = 49,123.54103861

Decoration

Multiply day and month with the end result in step (11) ..... (12)

 23 *5 * 49,123.54103861 = 5,649,207.21944015

Ignore decimals and flip the value you got ..... (13)

5,649,207.21944015 ==> 5,649,207 ==> 7029465

Just take first 5 digits of this number ...... (14)

7029465 ==> 70294

Put it in the oven and serve warm
and that is our random number
Bon Appétit...
another example
another test case
Step 1 :
Date Time = "23/07/2016 04:59:31.407"

Step 2 :
1 + 407 = 408

Step 3 :
1 + 31 = 32

Step 4 :
408 * 32 = 13,056

Step 5 :
13,056 / 360 = 36.26666667
Sin(36.26666667) = -0.9904447352

Step 6 :
-0.9904447352 * 1000 = -990.4447352

Step 7 :
(3 + 04) * 59 = 413

Step 8 :
413 + (-990.4447352) = -577.4447352

Step 9 :
Abs(-577.4447352) = 577.4447352

Step 10 :
First 2 digits (without leading zeroes) ==> 57
π Position 57 (5 numbers)==> 49445

Step 11 :
49445 + 577.4447352 = 50,022.4447352

Step 12 :
50,022.4447352 * 23 * 07 = 8,053,613.6023672

Step 13 :
8,053,613.6023672 ==> 8,053,613
8,053,613 ==> 3163508

Step 14 :
First 5 Number 3163508 ==> 31635

Feels like this could've been sandboxed first since it's an arbitrary fixed algorithm... also, multiply by the muints... what are muints?

muints is part of a group of words we call it "Typos". it is derived from the word minutes. it is like spices to the recipe..

Can you add more test cases?

05AB1E, 50 bytes
žd₄/îžc>*360/Å½₄*ža3+žb*+ÄDþ0K2£žss.$5£J+žežfPïR5£

Try it online.
Explanation:
žd              # Push current microseconds
  ₄/            # Divide by 1000
    î           # Round up (we now have milliseconds + 1) (2)
žc>             # Push current seconds + 1 (3)
*               # Multiply both with each other (4)
360/            # Divide it by 360
    Å½          # Get the sine of this (5)
₄*              # Multiply by 1000 (6)
ža3+            # Push the current hours + 3
    žb*         # Multiply it with the current minutes (7)
+               # Add it to the earlier number (8)
Ä               # Get the absolute value of this (9)
D               # Duplicate it
 þ              # Only leave the digits of the copy, removing the decimal dot
  0K            # Remove all 0s
    2£          # Only leave the first two digits
      žs        # Push an infinite list of PI digits
        s       # Swap to get the number of two digits to the top of the stack
         .$     # Remove that many leading digits from PI
           5£   # And then only leave the first 5 digits of the remainder of PI
             J  # Join the digits together to a single string/integer (10)
+               # Add it to the earlier number that we've duplicated (11)
že              # Push the current day
  žf            # Push the current month
    P           # Take the product of all three values on the stack (12)
ï               # Truncate any decimals
 R              # Reverse this integer (13)
5£              # Only leave the first five digits (14)
                # (which is output implicitly as result)

Python 3, 223 bytes
import datetime,math,sympy
d=datetime.datetime.now()
x=abs(math.sin((1+d.microsecond//1e3)*-~d.second/360)*1e3+(d.hour+3)*d.minute)
print(str(int(d.day*d.month*(int(str(sympy.pi.evalf(5+int(str(x)[:2])))[-5:])+x)))[:-6:-1])

Try it online!
-2 bytes thanks to ValueInk

Obligatory byte save by transforming a (1+x) into -~x (unfortunately doesn't work with the microsecond one because of the required division)

@ValueInk Right, thanks. I actually thought of that and then decided "oh it doesn't work because of the division" lmao

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

sort: votes


text:
Split into three!

Given a string, you've to split it into groups of three characters (by padding _ at the end).
Related, but still it's different.

Sample I/O:

'abcde' -> 'abc', 'de_'

'1234' -> '123', '4__'

'' -> [] or falsey value

'Three spree!' -> 'Thr', 'ee ', 'spr', 'ee!'

6 MB string

This is a code-golf, so fewest bytes will win!
Edit: Finally, output is unrestricted.

Why special case the empty string? May we choose which character to use for the padding?

Is null considered a falsey value?

@LuisfelipeDejesusMunoz, falsey values are defined by the language, not the challenge author.

05AB1E, 9 8 bytes
…___«3ô¨

Try it online!
or as a Test Suite
Explanation
…___«      # append "___" to input
     3ô    # split into groups of 3
       ¨   # discard the last group

Python 3, 58 47 34 bytes
I'm sure someone else can do better Someone else did better. Thanks Jo King for -11 -24 bytes!
Output is unrestricted, welcome to tuple hell. Returns empty list (falsy) on empty input
lambda x:[*zip(*[iter(x+"__")]*3)]

TIO

JavaScript, 25 bytes
s=>`${s}__`.match(/.../g)

Try it

APL+WIN 36 24 22 bytes
12 bytes saved as a result of output now being de-restricted and using the code in @Adám's first comment modified to work in APL+WIN and a further 2 with his second comment. Thanks.
(⌈(↑⍴s)÷3)3⍴(s←⎕),'__'

Prompts for input of the string and outputs the result as a nx3 array
Try it online! Courtesy of Dyalog Classic

@Adám. Throws a domain error in APL+WIN at the right most ⍴

Fails on '', no? I think OP (for some strange reason) requires the result to be 0 (with any rank).

@Adám It produces a 0 x 3 array. The OP now appears to want "falsey" for a null input. With the spec keeping on changing I am going to bow out at this point and leave my answer as its stands! Thanks for your improvements.

Perl 5, 16 15 bytes
"@_\__"=~/.../g

Try it online!

15 with "@_\__"=~/.../g. There were other 16s: (pop.__)=~/.../g or map/.../g,pop.__.

Thx to @Grimy for the tip on . It shaved off 1 byte and I learned something new.

JavaScript, 51 50 48 27 25
b=>(b+"__").match(/.../g)

Try it online!

Welcome to PPCG! :) But ... https://codegolf.stackexchange.com/a/185808/58974

@Shaggy I didn't even see that ¯\(ツ)/¯

No worries, it happens.

Perl 6, 19 bytes
{$_~"__"~~m:g/.../}

Try it online!
Pads the string by two underscores then splits the string into chunks of three characters. Returns as an array of Match objects.

Japt, 8 bytes
+1 byte to special case the empty string. Can save 2 if we can choose our padding character.
©ò3 ú'_3

Try it
©ò3 ú'_3     :Implicit input of string
©            :Logical AND with
 ò3          :Split into chunks of 3
    ú'_3     :Right pad each with "_" to length 3

Stax, 7 bytes
é☻εgP▀╪

Run and debug it
For an empty string input, the result is an empty array, which is a falsey value in stax.

CJam, 11 bytes
q'_3*+3/);p

Try it online!
For empty input this gives an empty string, which is falsy.
How it works
q     e# Read input as a string
'_    e# Push char '_'
3*    e# String formed by that char repeated 3 times
+     e# Concatenate to input string
3/    e# Split in groups of 3, the last of which may be shorter. Gives array of strings
);    e# Detach last string from the array and delete it
p     e# Print string representation of the array

Retina 0.8.2, 10 bytes
$
__
!`...

Try it online! Link includes test cases. Explanation:
$
__

Append two _s, in case the last group needs to be padded.
!`...

Match as many groups of three as possible, outputting the matches themselves rather than the count. (In Retina 1 this would be L instead of !.)

Wolfram Language (Mathematica), 28 21 bytes
-7: No longer requires falsy (False) value on empty input
Partition[#,3,1,1,_]&

Try it online!
Takes a list of characters as input. Returns a list of 3-tuples of characters padded with Blanks (_).

34 27 bytes
StringPartition[#<>"__",3]&

Try it online!
String input, list of strings output

C (gcc), 67 bytes
i;f(char*_){for(;*_;puts(""))for(i=3;i--;)putchar(*_?*_++:95);_=0;}

Try it online!
Always returns a falsey value (0).

Do you even need to return anything?

63 bytes

Ruby, 73 42 bytes
a=gets
a.length!=0?a.scan(/.{1,3}/).map{|s|(s+'_'*3)[0,3]}:'falsey value'

Edit: As falsey value looks like it's not required:
gets.scan(/.{1,3}/).map{|s|(s+'_'*3)[0,3]}

The maximum padding is of 2 characters, so '_'*2 would be enough, for which a literal '__' is shorter. But if you add the padding in advance then simply not match the pieces shorter than 3 characters, is shorter: puts"#{gets}__".scan /.../. (Note that without the explicit printing that is considered irb not ruby.)

29 bytes (note: -2 bytes with _1 syntax and -2 if a different padding character is allowed)

@AsoneTuhid - That's different enough to be posted as a separate answer! ;-)

C (clang), 128 126 94 67 63 bytes
63 bytes thanks to @ceilingcat.
f(char*k){for(;*k;k++)printf("%c%c%c\n",*k,*++k?:95,*++k?:95);}

Try it online!

Jelly, 9 bytes
s3o€“___”

A monadic Link accepting a list of characters which yields a list of lists of characters (an empty input yields empty output).
Try it online!
How?
s3o€“___” - Link: list of characters
s3        - split into chunks of three
   €      - for each chunk:
  o       -   OR (vectorises):
    “___” -     list of characters = ['_', '_', '_']

Notes:
The € is only necessary to handle the edge case of an empty input.
A full program can drop a trailing ”, but here we can't do that as the printing behaviour of a full program smashes everything together.

Equivalent 9:
o3ÐƤ“___”

Try it

Alternative 9:
;“___”s3Ṗ

Try it

J, 16 bytes
[:}:_3]\'___',~]

Try it online!
K (oK), 19 17 bytes
-2 bytes thanks to ngn!
{-1_0N 3#x,"___"}

Try it online!

k: (0N;3) -> 0N 3

Java 10, 116 113 bytes
s->{s+="__";int l=s.length()/3,i=l;var r=new String[l];for(;i-->0;)r[i]=s.substring(i*3,i*3+3);return l<1?0>1:r;}

Try it online.
Or 104 101 bytes if an empty array instead of false is allowed as output..
s->{s+="__";int l=s.length()/3;var r=new String[l];for(;l-->0;)r[l]=s.substring(l*3,l*3+3);return r;}

Try it online.
Explanation:
s->{                             // Method with String as both parameter and return-type
  s+="__";                       //  Append two "_" to the input-String
  int l=s.length()/3;            //  Get the length, integer-divided by 3
  var r=new String[l];           //  Create a string-array with that many parts
  for(;l-->0;)                   //  Loop `l` in the range (l, 0]:
    r[l]=                        //   Set the `l`'th value of the array to:
         s.substring(l*3,l*3+3); //   Get the substring of size 3 from index `l*3` from `s`
  return r;}                     //  Return the array

An empty array is now allowed

C# (Visual C# Interactive Compiler), 74 bytes
Just append two underscores '_' at the end of the input to make sure they get printed if the length of the input isn't a factor of 3.
s=>Enumerable.Range(0,(s.Length+2)/3).Select(i=>(s+"__").Substring(i*3,3))

Try it online!

67

57

Kotlin, 34 bytes
{"${it}__".chunked(3).dropLast(1)}

Try it online!

this does not work, try {"${it}___".chunked(3).dropLast(1)}

C (gcc), 55 bytes
i;f(char*s){for(;i%4|*s;)putchar(++i%4?*s?*s++:95:10);}

Try it online!

Using 9(\t) instead of 10(\n) should be fine, but that's not main point

Bash, 90 bytes
This uses Bash features rather than a combination of more traditional Bourne shell plus *nix commands (which one version I created ended up at 205 bytes). I cheated by using the dodge of adding two _ characters to the string.

c=;read a;a=${a}__;while (($(echo ${#a})>2));do b=${a:0:3};c=$c\ $b;a=${a#$b};done;echo $c

Try it online!

PowerShell, 58 35 bytes
$args-split'(...)'-ne''|% *ht 3 '_'

-23 bytes thanks to mazzy.
Try it online!

Nice. 1) You can count a code that can be extracted into a ps1-file and executed. 2) See shortcuts. 3) Try to golf more

GNU sed, 27 bytes
s:$:__:
s:...:& :g
s: _*$::

Try it online!
It gets a bit tricky regarding the empty string input, since sed has no meaning of a falsy value. So to deal with this, I provide you with two possible interpretations of the rules to validate my submission:

A. You essentially provide nothing as input, not even a trailing newline (as it is the case with all the examples, including that 6 Mb file).
Usage:
echo -n ""|sed -f script

Output: nothing is printed, because sed doesn't even run the script without input.

B. One could consider as falsy value for sed to be an unique string, i.e., returned only when the input is an empty string.
Usage:
echo ""|sed -f script

Output:
__

I prefer the first interpretation so much more, as I believe it to be the closest to the intended rule, but the last one helps if you run the script using that TIO link.

APL(NARS), 30 chars, 60 bytes
{(3/⍳3÷⍨≢v)⊂v←⍵,'_'⍴⍨3∣3-3∣≢⍵}

test:
  f←{(3/⍳3÷⍨≢v)⊂v←⍵,'_'⍴⍨3∣3-3∣≢⍵}
  ⎕fmt f 'abcde'
┌2────────────┐
│┌3───┐ ┌3───┐│
││ abc│ │ de_││
│└────┘ └────┘2
└∊────────────┘
  ⎕fmt f '1234'
┌2────────────┐
│┌3───┐ ┌3───┐│
││ 123│ │ 4__││
│└────┘ └────┘2
└∊────────────┘
  ⎕fmt f ''
┌0──┐
│┌0┐│
││ ││
│└¯┘2
└∊──┘
  ⎕fmt f 'Three spree!'
┌4──────────────────────────┐
│┌3───┐ ┌3───┐ ┌3───┐ ┌3───┐│
││ Thr│ │ ee │ │ spr│ │ ee!││
│└────┘ └────┘ └────┘ └────┘2
└∊──────────────────────────┘

Jelly, 6 bytes
s3Zz”_

Try it online!
How it works
s3Zz”_ - Main link. Takes a string S on the left
s3     - Split into chunks of 3
  Z    - Transpose
   z”_ - Transpose, using "_" as a filler

Vyxal, 7 bytes
3ẇ∩\_ÞṪ

Try it Online!
How?
3ẇ∩\_ÞṪ
3ẇ      # Split into chunks of three
  ∩     # Transpose
   \_ÞṪ # Transpose with "_" as filler

Factor + grouping.extras, 27 bytes
[ 3 95 pad-groups 3 group ]

Thunno 2, 5 bytes
³'_3Ŀ

Try it online!
³'_ƬṬ

Try it online!
Explanation
³'_3Ŀ  '# Implicit input
³       # Split into threes
    Ŀ   # Left-justify each,
 '_    '# padding with "_"s
   3    # to length 3
        # Implicit output

³'_ƬṬ  '# Implicit input
³       # Split into threes
   Ƭ    # Transpose with
 '_    '# filler "_"
    Ṭ   # Tranpose again
        # Implicit output

Haskell, 40 bytes
f(a:b:c:t)=[a,b,c]:f t
f _=[]
f.(++"__")

JavaScript (Babel Node), 45 bytes
_=>_.match(/.{1,3}/g).map(a=>a.padEnd(3,`_`))

Try it online!

44

Doesn't work for me

Jelly, 10 bytes
s3;€⁾__ḣ€3

Try it online!
It feels like an 8 or 9 should be possible, but haven’t found one yet.

Pyth, 10 9 bytes
Pc+z*3\_3

Try it online!
-1 from u_ndefined.
Is it ok if it throws an error on empty input? (does that count as falsey)

It works on TIO, but not on Pyth compiler/executor. Is there a reason? (i.e. Pyth compiler/executor is outdated?)

-1 byte

Attache, 34 23 bytes
PadRight&"_"&3=>@Chop&3

Try it online!
Explanation (outdated)
{On[#_-1,PadRight&"_"&3,_]}@Chop&3
                           @Chop&3    chop the input string into groups of 3s
{On[#_-1               ,_]}           on the last group
        ,PadRight                         pad it
                     &3                   to length three
                 &"_"                     with underscores

Would you save anything by padding all the elements instead of just the last one?

@Shaggy Good point! I’ll look into it

Charcoal, 10 bytes
Ｅ⪪Ｓ³…⁺ι__³

Try it online! Link is to verbose version of code. Explanation:
  Ｓ         Input string
 ⪪ ³        Split into groups of up to 3 characters
Ｅ           Map over each group
      ι     Current group
     ⁺      Concatenated with
       __   Literal `__`
    …    ³  Moulded to length 3
            Each group implicitly printed on its own line

Scala, 31 bytes
(s+"___").grouped(3).toSeq.init

Try it online!
Explanation
(s+"___")       // add "___"
  .grouped(3)   // make groups of 3
  .toSeq        // change to Seq
  .init         // take all but last

You'll have to add some part of the function definition in, otherwise you won't know where s is coming from

Befunge-93, 30 29 bytes
~:1+%,~:1+!"`"*+,~:1+!"`"*+,,

Try it online!
Outputs nothing for an empty input, otherwise outputs strings of length 3 separated by NUL characters.
Explanation:

~                               Push character of input to stack
 :1+                            Duplicate input and add 1
    %                           Modulo top 2 values of stack and push result
                                If input was -1 (end of stream), calculate -1%0 -> halt
                                Otherwise calculate input%(input+1) -> input
     ,                          Pop and output character
      ~                         Push character of input to stack
       :1+!                     Duplicate input, add 1 and perform logical NOT
           "`"*                 Multiply by 96 (ASCII code for '`')
                                This returns 96 or 0 depending on the result of the NOT
               +                Add the top 2 values from the stack and push the result
                                If the input was -1 (end of stream), pushes -1+96=95, or the ASCII code for '_'
                                Otherwise pushes input+0
                ,               Pop and output character
                 ~:1+!"`"*+,    Same block again to handle the third character
                            ,   Output a NUL character (stack is empty, so popping from stack just returns 0)

The instruction pointer wraps around at the end, looping the entire line.

Haskell, 62 61 59 bytes
z(a:b:c:d)=[a,b,c]:z d
f s=takeWhile(/="___")$z$s++cycle"_"

Infinite lists and strings!
Try it online!

Rust, 93 bytes
Works for ASCII input strings. Empties the input string and returns a Vec<String>.
|mut s:String|{s+="__";let mut v=vec![];while s.len()>2{let t=s.split_off(3);v.push(s);s=t}v}

Try It Online

GoLang, 84 bytes
func(x string)[]string{return regexp.MustCompile("...").FindAllString(x+"__",-1)}(s)

Try it !

SNOBOL4 (CSNOBOL4), 93 bytes
	S =INPUT
	S =S DUPL('_',REMDR(3 - REMDR(SIZE(S),3),3))
R	S LEN(3) . OUTPUT REM . S	:S(R)
END

Try it online!
SNOBOL has a size limit on the length of its input (1023 bytes).

Julia 1.0, 40 bytes
s->[(s*"__")[i:i+3] for i=1:3:length(s)]

Try it online!

37 bytes

GolfScript, 10 bytes
"___"+3/);

Try it online!

Husk, 9 6 bytes
TT'_C3

Try it online!
look ma, no unicode!(-3)
Explanation
TT'_C3
    C3 cut into pieces of 3
 T'_   transpose, padding with underscore
T      transpose again

Ruby, 27 21 bytes
p"#{$_}__".scan /.../

Try it online!
-6 bytes thanks to vrintle

Saved 6 bytes more, Try it online!. BTW, do you know why it fails for multiline input? Though, it's not a part of this challenge..

Nibbles, 8 bytes (16 nibbles)
In literal form:
`/3;_<3:$"__"

Attempt This Online!
`/             chunks of
  3              3 characters
   ;_            for input string
               then, apply map(\chunk->...):
     <3          take first 3 characters of
       :$"__"    concatenation of chunk and "__"

Rattle, 21 bytes
\__|!II^/3P[[gb>]3B]`

Try it Online!
Outputs groups of 3 separated by newlines.
Explanation:
\__|                  take input and concatenate "__"
    !                 disable implicit output
     I                save characters of the input in consecutive memory slots
      I^              get length of the input
        /3            divide by 3 to get n
          [...]`      loop n times (ignoring any values after the decimal point)

[...]3                loop 3 times
 g                    get the character at the pointer
  b                   add this character to the print buffer
   >                  move pointer right
      B               print contents of buffer and reset

Uiua SBCS, 8 bytes
⬚@_↯¯1_3

Try it!

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
Surface of the 3x3x3 cube as a graph
Your task is to generate a graph with 54 vertices, each corresponds to a facet on a Rubik's cube. There is an edge between two vertices iff the corresponding facets share a side.
Rules

You may choose to output an adjacency list, adjacency matrix, edge list, or any reasonable format to represent a graph in an algorithm. (A visual graph readable by a human is generally not a reasonable format in an algorithm in most cases.)
You may make either every vertex adjacent to itself, or none adjacent to itself.
You may either include both directions for each edge (count one or two times for self-loops), or output exactly one time for each edge, but not mix the ways.
You may renumber the vertices, skip some numbers, or even use non-number labels for the vertices in any way you want. You should also post the numbering if it isn't obvious, so others could check your answer in easier ways.
This is code-golf. Shortest code in bytes wins.

Example output
This is the numbering of vertices used in the example:
          0  1  2
          3  4  5
          6  7  8
 9 10 11 18 19 20 27 28 29 36 37 38
12 13 14 21 22 23 30 31 32 39 40 41
15 16 17 24 25 26 33 34 35 42 43 44
         45 46 47
         48 49 50
         51 52 53

Output as an adjacency list (vertex number before each list is optional):
0 [1 3 9 38]
1 [2 4 0 37]
2 [29 5 1 36]
3 [4 6 10 0]
4 [5 7 3 1]
5 [28 8 4 2]
6 [7 18 11 3]
7 [8 19 6 4]
8 [27 20 7 5]
9 [10 12 38 0]
10 [11 13 9 3]
11 [18 14 10 6]
12 [13 15 41 9]
13 [14 16 12 10]
14 [21 17 13 11]
15 [16 51 44 12]
16 [17 48 15 13]
17 [24 45 16 14]
18 [19 21 11 6]
19 [20 22 18 7]
20 [27 23 19 8]
21 [22 24 14 18]
22 [23 25 21 19]
23 [30 26 22 20]
24 [25 45 17 21]
25 [26 46 24 22]
26 [33 47 25 23]
27 [28 30 20 8]
28 [29 31 27 5]
29 [36 32 28 2]
30 [31 33 23 27]
31 [32 34 30 28]
32 [39 35 31 29]
33 [34 47 26 30]
34 [35 50 33 31]
35 [42 53 34 32]
36 [37 39 29 2]
37 [38 40 36 1]
38 [9 41 37 0]
39 [40 42 32 36]
40 [41 43 39 37]
41 [12 44 40 38]
42 [43 53 35 39]
43 [44 52 42 40]
44 [15 51 43 41]
45 [46 48 17 24]
46 [47 49 45 25]
47 [33 50 46 26]
48 [49 51 16 45]
49 [50 52 48 46]
50 [34 53 49 47]
51 [52 44 15 48]
52 [53 43 51 49]
53 [35 42 52 50]

APL (Dyalog Classic), 34 30 bytes
-4 thanks to jimmy23013
4≥+/¨|∘.-⍨,(⍳3)∘.⌽7 ¯1∘.,○⍳3 3

Try it online!
outputs an adjacency matrix with each vertex adjacent to itself
⍳3 3 generate an array of (0 0)(0 1)(0 2)(1 0)(1 1)(1 2)(2 0)(2 1)(2 2)
○ multiply all by π
7 ¯1∘., prepend 7 or -1 in all possible ways
(⍳3)∘.⌽ rotate coord triples by 0 1 2 steps in all possible ways
+/¨|∘.-⍨, compute manhattan distance between each pair
4≥ it must be no greater than 4 for neighbouring facets

@jimmy23013 using π is very nice :) thank you!

54x54 matrix... thats impressive

This is the most obfuscated, golfed solution I've ever seen

Ruby, 60 bytes
i=0;("$$5$$1$Hu"*6).bytes{|j|p [(j/18+i+=1)%54,(j%18+i)%54]}

Try it online!
Improved version of my original answer. We split the surface of the cube into squares of 9 (instead of rectangles of 18 as before) and use a magic string rather than a formula to generate the offsets. The output is a list of the nodes below and to the right of each node in the (revised) map below, as before.
Output map in base 10 as shown in the output
(each node is linked to the nodes below and to the right)
0  3  6  9 10 11
1  4  7 12 13 14
2  5  8 15 16 17
        18 21 24 27 28 29
        19 22 25 30 31 32
        20 23 26 33 34 35
                 36 39 42 45 46 47
                 37 40 43 48 49 50
                 38 41 44 51 52 53

Output map in base 9 (to show more clearly how it works.)
Note that each square of 9 has the same first digit. The last digits repeat 0,1,2 on the free edge and 0,3,6 on the attached edge (alternating between horizontal and vertical.)
In one direction the next node is 3 higher (except when crossing to the next square, when it is 3,5 or 7 higher) and in the other direction it is 1 higher (except when crossing to the next square, when it is [base 10] 18, 14 or 10 higher = [base 9] 20, 16 or 12 higher.)
This info is encoded into the magic string, where the ASCII code of each character is 18*[2,4 or 6]+[17,13,10 or 0]. Incrementing i at the beginning of each iteration boosts these values by 1.
00 03 06 10 11 12
01 04 07 13 14 15
02 05 08 16 17 18
         20 23 26 30 31 32
         21 24 27 33 34 35
         22 25 28 36 37 38
                  40 43 46 50 51 52
                  41 44 47 53 54 55
                  42 45 48 56 57 59

Ruby, 79 bytes
54.times{|i|p [(i%6<5?i+1:i+18-i/6%3*7)%54,(i+=i%18<12?6:[18-i%6*7,3].max)%54]}

Try it online!
Prints a representation of a unidirectional graph, as a list of the vertices to the right of and below each vertex as shown in the map below.
 0  1  2  3  4  5
 6  7  8  9 10 11
12 13 14 15 16 17
         18 19 20 21 22 23
         24 25 26 27 28 29
         30 31 32 33 34 35
                  36 37 38 39 40 41
                  42 43 44 45 46 47
                  48 49 50 51 52 53

Python 2.7, 145
def p(n):l=(3-n%2*6,n/6%3*2-2,n/18*2-2);k=n/2%3;return l[k:]+l[:k]
r=range(54)
x=[[sum((x-y)**2for x,y in zip(p(i),p(j)))<5for i in r]for j in r]

Try it online!
Defines an adjacency matrix x as a list of lists of boolean values. Facets count as being adjacent to themselves.
p(n) computes the coordinates of the center of the nth facet of a 3x3x3 cube whose facets are 2 units across. Adjacency is determined by testing if 2 facets have a square distance under 5 (adjacent facets have square distance at most 4, non-adjacent facets have square distance at least 6).

Charcoal, 48 bytes
Ｆ⁷Ｆ⁷Ｆ⁷⊞υ⟦ικλ⟧≔Φυ⁼Φ﹪ι⁶¬﹪λ²⟦⁰⟧υＩＥυΦＬυ⁼²ΣＥ§υλ↔⁻ν§ιξ

Try it online! Link is to verbose version of code. Explanation:
Ｆ⁷Ｆ⁷Ｆ⁷⊞υ⟦ικλ⟧

Generate all sets of 3-dimensional coordinates in the range [0..6] for each dimension.
≔Φυ⁼Φ﹪ι⁶¬﹪λ²⟦⁰⟧υ

Keep only those coordinates that are centres of 2x2 squares on one of the faces x=0, y=0, z=0, x=6, y=6, z=6.
ＩＥυΦＬυ⁼²ΣＥ§υλ↔⁻ν§ιξ

For each coordinate, print the indices of those coordinates whose taxicab distance is 2.
The vertices are numbered as follows:
         33 34 35
         21 22 23
          9 10 11
36 24 12  0  1  2 13 25 37 47 46 45
38 26 14  3  4  5 15 27 39 50 49 48
40 28 16  6  7  8 17 29 41 53 52 51
         18 19 20
         30 31 32
         42 43 44

is there any documentation for charcoal on the web ?

@donbright Follow the GitHub link in the answer title and click Wiki.

Wolfram Language 190 bytes
The following returns all of the graph edges in terms of the actual coordinates (assuming each mini-cube is 2 units at the edge and the Rubik's cube has its bottom left vertex at the origin).
t=Table;h[a_,b_,c_]:=t[{x,y,z},{a,1,5,2},{b,1,5,2},{c,0,6,6}];Partition[Sort[a=Cases[DeleteCases[Tuples[Flatten[{h[x,z,y],h[y,z,x],h[x,y,z]},3],{2}],{x_,x_}],x_/;ManhattanDistance@@x==2]],4]

(* output *)
{{{{0,1,1},{0,1,3}},{{0,1,1},{0,3,1}},{{0,1,1},{1,0,1}},{{0,1,1},{1,1,0}}},{{{0,1,3},{0,1,1}},{{0,1,3},{0,1,5}},{{0,1,3},{0,3,3}},{{0,1,3},{1,0,3}}},{{{0,1,5},{0,1,3}},{{0,1,5},{0,3,5}},{{0,1,5},{1,0,5}},{{0,1,5},{1,1,6}}},{{{0,3,1},{0,1,1}},{{0,3,1},{0,3,3}},{{0,3,1},{0,5,1}},{{0,3,1},{1,3,0}}},{{{0,3,3},{0,1,3}},{{0,3,3},{0,3,1}},{{0,3,3},{0,3,5}},{{0,3,3},{0,5,3}}},{{{0,3,5},{0,1,5}},{{0,3,5},{0,3,3}},{{0,3,5},{0,5,5}},{{0,3,5},{1,3,6}}},{{{0,5,1},{0,3,1}},{{0,5,1},{0,5,3}},{{0,5,1},{1,5,0}},{{0,5,1},{1,6,1}}},{{{0,5,3},{0,3,3}},{{0,5,3},{0,5,1}},{{0,5,3},{0,5,5}},{{0,5,3},{1,6,3}}},{{{0,5,5},{0,3,5}},{{0,5,5},{0,5,3}},{{0,5,5},{1,5,6}},{{0,5,5},{1,6,5}}},{{{1,0,1},{0,1,1}},{{1,0,1},{1,0,3}},{{1,0,1},{1,1,0}},{{1,0,1},{3,0,1}}},{{{1,0,3},{0,1,3}},{{1,0,3},{1,0,1}},{{1,0,3},{1,0,5}},{{1,0,3},{3,0,3}}},{{{1,0,5},{0,1,5}},{{1,0,5},{1,0,3}},{{1,0,5},{1,1,6}},{{1,0,5},{3,0,5}}},{{{1,1,0},{0,1,1}},{{1,1,0},{1,0,1}},{{1,1,0},{1,3,0}},{{1,1,0},{3,1,0}}},{{{1,1,6},{0,1,5}},{{1,1,6},{1,0,5}},{{1,1,6},{1,3,6}},{{1,1,6},{3,1,6}}},{{{1,3,0},{0,3,1}},{{1,3,0},{1,1,0}},{{1,3,0},{1,5,0}},{{1,3,0},{3,3,0}}},{{{1,3,6},{0,3,5}},{{1,3,6},{1,1,6}},{{1,3,6},{1,5,6}},{{1,3,6},{3,3,6}}},{{{1,5,0},{0,5,1}},{{1,5,0},{1,3,0}},{{1,5,0},{1,6,1}},{{1,5,0},{3,5,0}}},{{{1,5,6},{0,5,5}},{{1,5,6},{1,3,6}},{{1,5,6},{1,6,5}},{{1,5,6},{3,5,6}}},{{{1,6,1},{0,5,1}},{{1,6,1},{1,5,0}},{{1,6,1},{1,6,3}},{{1,6,1},{3,6,1}}},{{{1,6,3},{0,5,3}},{{1,6,3},{1,6,1}},{{1,6,3},{1,6,5}},{{1,6,3},{3,6,3}}},{{{1,6,5},{0,5,5}},{{1,6,5},{1,5,6}},{{1,6,5},{1,6,3}},{{1,6,5},{3,6,5}}},{{{3,0,1},{1,0,1}},{{3,0,1},{3,0,3}},{{3,0,1},{3,1,0}},{{3,0,1},{5,0,1}}},{{{3,0,3},{1,0,3}},{{3,0,3},{3,0,1}},{{3,0,3},{3,0,5}},{{3,0,3},{5,0,3}}},{{{3,0,5},{1,0,5}},{{3,0,5},{3,0,3}},{{3,0,5},{3,1,6}},{{3,0,5},{5,0,5}}},{{{3,1,0},{1,1,0}},{{3,1,0},{3,0,1}},{{3,1,0},{3,3,0}},{{3,1,0},{5,1,0}}},{{{3,1,6},{1,1,6}},{{3,1,6},{3,0,5}},{{3,1,6},{3,3,6}},{{3,1,6},{5,1,6}}},{{{3,3,0},{1,3,0}},{{3,3,0},{3,1,0}},{{3,3,0},{3,5,0}},{{3,3,0},{5,3,0}}},{{{3,3,6},{1,3,6}},{{3,3,6},{3,1,6}},{{3,3,6},{3,5,6}},{{3,3,6},{5,3,6}}},{{{3,5,0},{1,5,0}},{{3,5,0},{3,3,0}},{{3,5,0},{3,6,1}},{{3,5,0},{5,5,0}}},{{{3,5,6},{1,5,6}},{{3,5,6},{3,3,6}},{{3,5,6},{3,6,5}},{{3,5,6},{5,5,6}}},{{{3,6,1},{1,6,1}},{{3,6,1},{3,5,0}},{{3,6,1},{3,6,3}},{{3,6,1},{5,6,1}}},{{{3,6,3},{1,6,3}},{{3,6,3},{3,6,1}},{{3,6,3},{3,6,5}},{{3,6,3},{5,6,3}}},{{{3,6,5},{1,6,5}},{{3,6,5},{3,5,6}},{{3,6,5},{3,6,3}},{{3,6,5},{5,6,5}}},{{{5,0,1},{3,0,1}},{{5,0,1},{5,0,3}},{{5,0,1},{5,1,0}},{{5,0,1},{6,1,1}}},{{{5,0,3},{3,0,3}},{{5,0,3},{5,0,1}},{{5,0,3},{5,0,5}},{{5,0,3},{6,1,3}}},{{{5,0,5},{3,0,5}},{{5,0,5},{5,0,3}},{{5,0,5},{5,1,6}},{{5,0,5},{6,1,5}}},{{{5,1,0},{3,1,0}},{{5,1,0},{5,0,1}},{{5,1,0},{5,3,0}},{{5,1,0},{6,1,1}}},{{{5,1,6},{3,1,6}},{{5,1,6},{5,0,5}},{{5,1,6},{5,3,6}},{{5,1,6},{6,1,5}}},{{{5,3,0},{3,3,0}},{{5,3,0},{5,1,0}},{{5,3,0},{5,5,0}},{{5,3,0},{6,3,1}}},{{{5,3,6},{3,3,6}},{{5,3,6},{5,1,6}},{{5,3,6},{5,5,6}},{{5,3,6},{6,3,5}}},{{{5,5,0},{3,5,0}},{{5,5,0},{5,3,0}},{{5,5,0},{5,6,1}},{{5,5,0},{6,5,1}}},{{{5,5,6},{3,5,6}},{{5,5,6},{5,3,6}},{{5,5,6},{5,6,5}},{{5,5,6},{6,5,5}}},{{{5,6,1},{3,6,1}},{{5,6,1},{5,5,0}},{{5,6,1},{5,6,3}},{{5,6,1},{6,5,1}}},{{{5,6,3},{3,6,3}},{{5,6,3},{5,6,1}},{{5,6,3},{5,6,5}},{{5,6,3},{6,5,3}}},{{{5,6,5},{3,6,5}},{{5,6,5},{5,5,6}},{{5,6,5},{5,6,3}},{{5,6,5},{6,5,5}}},{{{6,1,1},{5,0,1}},{{6,1,1},{5,1,0}},{{6,1,1},{6,1,3}},{{6,1,1},{6,3,1}}},{{{6,1,3},{5,0,3}},{{6,1,3},{6,1,1}},{{6,1,3},{6,1,5}},{{6,1,3},{6,3,3}}},{{{6,1,5},{5,0,5}},{{6,1,5},{5,1,6}},{{6,1,5},{6,1,3}},{{6,1,5},{6,3,5}}},{{{6,3,1},{5,3,0}},{{6,3,1},{6,1,1}},{{6,3,1},{6,3,3}},{{6,3,1},{6,5,1}}},{{{6,3,3},{6,1,3}},{{6,3,3},{6,3,1}},{{6,3,3},{6,3,5}},{{6,3,3},{6,5,3}}},{{{6,3,5},{5,3,6}},{{6,3,5},{6,1,5}},{{6,3,5},{6,3,3}},{{6,3,5},{6,5,5}}},{{{6,5,1},{5,5,0}},{{6,5,1},{5,6,1}},{{6,5,1},{6,3,1}},{{6,5,1},{6,5,3}}},{{{6,5,3},{5,6,3}},{{6,5,3},{6,3,3}},{{6,5,3},{6,5,1}},{{6,5,3},{6,5,5}}},{{{6,5,5},{5,5,6}},{{6,5,5},{5,6,5}},{{6,5,5},{6,3,5}},{{6,5,5},{6,5,3}}}}

The work of generating the points on each external facet is done by the function, h.
It has to be called 3 times to generate the points at x=0, x=6; y=0, y=6; and z=0,z=6.
Each facet point that is a Manhattan distance of 2 units from another will be connected to the respective point.
We can display the graph edges visually by the following; a is the list of graph edges that are represented below as arrows.
Graphics3D[{Arrowheads[.02],Arrow/@a},Boxed->False,Axes-> True]

The following shows the Rubik's cube, the points on the external facets, and 8 graph edges.

Red dots are located on facets at y = 0 and y = 6; blue and gray dots are on facets at x = 6 and x = 0, respectively; black dots are on facets at z=6 and  z=0.

nice pictures, arrowheads is really cool

Rust - 278 bytes
fn main(){let mut v=vec![];for x in vec![-2,0,2]{for y in vec![-2,0,2]{for z in vec![-2,2]{v.push([-1,z,x,y]);v.push([0,x,y,z]);v.push([1,x,z,y]);}}}for r in 0..54{print!("\n{} ",r);for s in 0..54{if (0..4).map(|n|v[r][n]-v[s][n]).map(|d|d*d).sum::<i32>()<5{print!("{} ",s)}}}}

Try on play.rust-lang.org
This is big, but the smallest code for a compiled language (so far). It creates an adjacency list. Its very similar to cardboard_box 's python answer but I wanted to see if Quaternions could work.
Step 1: Construct 54 Quaternions, each representing a single facet.
Step 2: for each Quaternion, list all other Quaternions with Quadrance (aka squared distance, aka squared norm of the difference)  <= 4.
Quaternions are built like so: The imaginary vectors i j k are points on the shell of a grid, from -2,-2,-2 to 2,2,2, step 2. The real part w is always -1, 0, or 1, so that facets on opposite sides of the cube have the same real part, but adjacent sides have different real parts. The real part allows distinguishing different 'sides' of the cube through calculation.
Quaternion numbering (pseudo isometric 3d view of a cube):
   ->i  ^j  \k

                  -2,+2,+2   +0,+2,+2  +2,+2,+2
                  -2,+0,+2   +0,+0,+2  +2,+0,+2
                  -2,-2,+2   +0,-2,+2  +2,-2,+2
                       w=0

   -2,+2,+2       -2 +2 +2   +0 +2 +2   +2 +2 +2     +2,+2,+2
   -2,+0,+2                                          +2,+0,+2
   -2,-2,+2       -2 -2 +2   +0 -2 +2   +2 -2 +2     +2,-2,+2

     -2,+2,+0       -2 +2 +0   +0 +2 +0   +2 +2 +0     +2,+2,+0
     -2,+0,+0                                          +2,+0,+0
     -2,-2,+0       -2 -2 +0   +0 -2 +0   +2 -2 +0     +2,-2,+0

       -2,+2,-2       -2 +2 -2   +0 +2 -2   +2 +2 -2     +2,+2,-2
       -2,+0,-2             w=1                          +2,+0,-2
       -2,-2,-2       -2 -2 -2   +0 -2 -2   +2 -2 -2     +2,-2,-2
           w=-1             w=1                              w=-1

                       -2,+2,-2   +0,+2,-2  +2,+2,-2
                       -2,+0,-2   +0,+0,-2  +2,+0,-2
                       -2,-2,-2   +0,-2,-2  +2,-2,-2
                            w=0

Indexed numbering (unfolded cube):
                    16 34 52
                    10 28 46
                     4 22 40
         48 30 12   14 32 50  15 33 51
         42 24  6    8 26 44   9 27 45
         36 18  0    2 20 38   3 21 39
                     1 19 37
                     7 25 43
                    13 31 49
                     5 23 41
                    11 29 47
                    17 35 53

JavaScript (ES6, Browser), 153 bytes
for(F=n=>(A=[n%9/3|0,n%3]).splice(n/18,0,(n/9&1)*3-.5)&&A,i=0;i<54;i++)for([a,b,c]=F(i),j=0;j<54;Math.hypot(a-d,b-e,c-f)>1||alert([i,j]),j++)[d,e,f]=F(j)

Try it online!
This is modified to reduce 5 bytes by making same points adjacent, i.e. \$||\mathbf{A-B}||\leq1\$.
JavaScript (ES6, Browser), 158 bytes
for(F=n=>(A=[n%9/3|0,n%3]).splice(n/18,0,(n/9&1)*3-.5)&&A,i=0;i<54;i++)for([a,b,c]=F(i),j=0;j<54;Math.hypot(a-d,b-e,c-f)>1||i-j&&alert([i,j]),j++)[d,e,f]=F(j)

Try it online! (simulates alert with console.log)
Maps the center of all 54 facets to the 3-d space and calculates whether \$0<||\mathbf{A-B}||\leq1\$ for every pair of points. Outputs all directed edges as pairs of numbers [a, b]. The vertex map is
47 50 53
46 49 52
45 48 51
20 23 26 11 14 17 35 32 29  8  5  2
19 22 25 10 13 16 34 31 28  7  4  1
18 21 24  9 12 15 33 30 27  6  3  0
36 39 42
37 40 43
38 41 44

i didnt even know there was a Math.hypot


text:
Knights and Knaves and Codes
In this challenge, your bot has landed on an island with the stereotypical knights and knaves. Knights always tell the truth, and knaves always lie. The objective is to find the correct 32 digit hexadecimal string before anyone else, by asking knights and knaves and trying to trick other bots into giving you answers or accepting fake ones.
Knights and Knaves
Every bot will be given an array of 48 people, who are the same for all bots. The bots do not know whether any one person is a knight or knave. Each person is assigned two characters of the 32 digit string. Exactly half of all people are knights, and half are knaves: a knight will always give you the correct characters and their indexes within the result string; a knave, however, will give an incorrect character each time along with the correct index. These incorrect characters will always be the same for any one bot, so a knave is indistinguishable from a knight without outside help or some deductive skills. Every character of the string is known by exactly three people, and no person has the same character twice.
Interacting
In order to find knaves, bots can interact with one another. One bot will request help from another for a specific character of the string, and the second bot can return any character. It is up to the first bot to decide if this character is real or fake, likely by asking for more help and comparing the results.
In order to prevent help-vampire bots, no bot can have more outgoing help requests than twice the number of incoming requests it has answered, plus four.
Bots
Every bot is assigned a random Unique ID (UID) number each round. This number is used to communicate with other bots, and ranges from 0 to one less than the number of bots. It can request help from another bot using the function sendRequest(uid, index), and read from responses with readResponses(), which is formatted as an array/list of objects containing uid, index, and char properties.
Additionally, a bot can view the requests sent to it using viewRequests(). Each request is an object containing two properties: index, and uid. To reply to a request, use the function replyRequest(uid, index, char). There must be a request in viewRequests() from that UID asking about the index specified in order for this to work, and char must be a hexadecimal character.
Both sendRequest and replyRequest will output false if something is invalid (UID for sendRequest, and no request to reply to for replyRequest), and true otherwise.
The bot will receive three arguments as input to its function. The first is an array/list of each knight/knave, with each one represented as an array/list of two objects (index and char are their properties).
The second argument is the number of bots. UIDs range from zero to one less than this number. Finally, the third argument is an empty object, which the bot can use to store any information it needs.
Rules

The bot can be programmed in JavaScript (heavily recommended), Python, or any language with functions, strings, numbers, arrays/lists, and objects/dictionaries/hash maps
All bots will be converted to JavaScript to be run in the controller
A bot may not read or modify any variables outside of its function arguments and local/function scoped variables it creates
A bot may not execute any functions declared outside its scope, aside from the four interaction functions (sendRequest, readResponses, viewRequest, and replyRequest)
Your bot's guess is submitted by return value. If it does not know, it can return null/false/undefined, or a random guess. Each bot has a win count. If multiple bots guess correctly in the same turn, this increments by 1/correctGuesses
Standard Loopholes are prohibited, per the usual
Controller, Chatroom
By the way, this is not a dupe. The other questions based around knights and knaves have a very different objective, they are just similar in their topic

So? How do you win? By looking at the controller, it seems bots have to submit guesses using the return value of their run function, but this isn't mentioned in the question.

@Grimy Oh, just forgot to mention the return value is the guess. It does say "The objective is to find the correct 32 digit hexadecimal string before anyone else", I just forgot to specify how (:

Okay, but, "before anyone else" how?  Is it time based, or number of responses received?  Is it valid to answer responses from particular bots and not others?  Why would I not return a random response to any request?

@Spitemaster Just updated the code and the explanation along with the page

Third issue: if I write a function inside my bot to validate data before calling sendRequest, the callee.caller results in an invalid value (from is null and not null checked). More "annoying and results in code duplication" than a bug.

Fourth, without a sufficient supply of never-lying bots that divulge only information they've gathered that they can't determine to be true, it is impossible to deduce the string. Only about half the string can be discovered by verifying knights (with a small possibility that two knaves pick the same wrong value, but we'll ignore that for the moment). That leaves 16 characters with 16 possible states ("did I find two knaves and a knight or 3 knaves?" indetermination), or 18 pentillion possible guess.

@Draco18s But, if you might have gotten a knight, that's more likely to be correct

Not really. NNN happens about 4 times on average for every new password. So even if we take KNN as more likely (there will be 12 on average) and assume that all NNN are KNN, and assume that NN# isn't masquerading as KK# (1:256 odds) we still have 16 positions with 3 possible values, or 4096 variations, to check before having to give up and assume that all KNN are NNN (because even one of them is enough to make sure that none of those 4096 are the right password). Even if we COULD identify which singular position is NNN and not KNN, that results in 186,535,791 possible passwords.

Zero Information Bot
function ZeroInformationBot(people, bots, data) {
    if (!data) {
        data = {
            botData: [],
            knaves: [],
            guess: "",
            newKnaves: false,
            attestations: Array(36).fill(0),
            threshold: -5,
        };
    }
    let newResponses = [];
    readResponses().forEach(res => {
        if (!data.botData[res.uid][res.index]){
            newResponses.push(res);
            data.botData[res.uid][res.index] = res.char;
        }
    });
    newResponses.forEach(res => {
        if (people.find(p => (p[0].index == res.index && p[0].char == res.char) || (p[1].index == res.index && p[1].char == res.char))){
            people.forEach((p, i) => {
                if ((p[0].index == res.index && p[0].char == res.char) || (p[1].index == res.index && p[1].char == res.char)) data.attestations[i] += 2;
                if ((p[0].index == res.index && p[0].char != res.char) || (p[1].index == res.index && p[1].char != res.char)) data.attestations[i] -= 1;
                if (data.attestations[i] < -1 && !data.knaves.find(i)) {
                    data.knaves.push(i);
                    data.newKnaves = true;
                }
            });
        }
    });
    viewRequests().forEach(req => {
        if (!data.botData[req.uid]){
            data.botData[req.uid] = Array(36).fill([]);
        } else if (!data.botData[req.uid][req.index]) {
            sendRequest(req.uid, req.index);
            data.botData[req.index] = "-"
        } else if (data.botData[req.uid][req.index] != "-") {
            replyRequest(req.uid, req.index, data.botData[req.uid][req.index]);
        }
    });
    if (!data.newKnaves && data.guess) return data.guess;
    data.newKnaves = false;
    let detected = true;
    let loop = false;
    let possibilities;
    while (detected){
        detected = false;
        possibilities = Array(36).fill(new Set());
        let examined = [], chargroups = [];
        people.forEach((p, i) => {
            if (data.knaves.find(i)) return;
            possibilities[p[0].index].add(p[0].char);
            possibilities[p[1].index].add(p[1].char);
            let first = examined.find(e => e.index == p[0].index && e.char == p[0].char);
            let second = examined.find(e => e.index == p[1].index && e.char == p[1].char);
            if (first && !second){
                chargroups[first.group].push(p[1]);
                examined.push({index: p[1].index, char: p[1].char, group: first.group});
            } else if (!first && second){
                chargroups[second.group].push(p[0]);
                examined.push({index: p[0].index, char: p[0].char, group: second.group});
            } else if (!first && !second){
                examined.push({index: p[0].index, char: p[0].char, group: chargroups.length});
                examined.push({index: p[1].index, char: p[1].char, group: chargroups.length});
                chargroups.push(p);
            } else if (first && second && first.group != second.group){
                chargroups[first.group].push(...chargroups[second.group]);
                examined = examined.map(e => {
                    if (e.group == second.group) e.group = first.group;
                    return e;
                });
                chargroups.splice(second.group, 1);
            }
        });
        possibilities.forEach((p, i) => {
            if (p.size == 1) {
                let char = Array.from(p)[0];
                chargroups.forEach(c => {
                    if (c.find(ch => ch.index == i && ch.char != char)) {
                        people.forEach((person, j) => {
                            if (data.knaves.find(j)) return;
                            // We don't need to check both characters; if one's in the group they both are.
                            if (c.find(ch => ch.index == person[0].index && ch.char == person[0].char)) {
                                data.knaves.push(j);
                                detected = true;
                            }
                        });
                    }
                });
            } else if (p.size == 0) {
                // Uh oh... need to reset.
                data.knaves = [];
                data.attestations.forEach((a, i) => {
                    if (a <= data.threshold) data.knaves.push(i);
                });
                detected = true;
                // Don't get stuck in a loop.
                if (loop) data.threshold--;
                loop = true;
            }
        });
    }
    data.guess = possibilities.map(p => Array.from(p)[0]).join("");
    return data.guess;
}

This bot lets out exactly zero information.  Whenever it's asked about something, it responds by first asking what that bot thinks, and then it replies with that data.
It counts up the number of times that other bots have given it one of the values of one of the people, and uses that to give a rough confidence score to each person, tentatively marking someone as a knave if they hit -2.  If it hits a paradox, it resets who it's considering as a knave, but only automatically re-marks someone as a knave if they have a score of -5 or worse.
Because this bot doesn't aggressively attempt to solve, it's quite possible it'll get stuck on one or two people for a long time; I'm interested in how well it will do.  I haven't tested it yet, as it seems the controller is still (slightly) in flux.

@Draco18s Thanks, I've fixed those you've pointed out - though the () is unneeded for new Set and var isn't needed (I wasn't trying to make this the cleanest code...).  I cleaned those up anyway, though.  Also, I'm uncertain why you feel my indentation is inconsistent.

Line 102 also throws possibilities not defined because it is declared inside of, but used outside of, the while loop. Line 103 throws guess is not defined (you want data.guess). Additionally, making the same guess with no new information is not a smart strategy.

Ah, that makes sense.  Of course, it's a moot point if there isn't a good resolution of the "no reason to give data" issue.

Oh, sure, in the absence of (enough) other bots you'll never gather any information, at which point you just have to make guesses at random. But you may as well make guesses at random.

Found another issue: chargroups will occasional be smaller than first.group or second.group throwing cannot read property 'push' of undefined on 57, 60, or 67.

TotallyRandomBot
(Hey, first time posting!)
TotallyRandomBot literally just guesses randomly, (maybe) eventually arriving at the answer through brute force. Keeping true to its random nature, it always replies with a random character when asked for help. Will it find the answer fast? No. Will it eventually find the answer, while throwing others off? Quite possibly.

function TotallyRandomBot(people, bots, data) {
  // string of length 32
  let guess = "00000000000000000000000000000000";
  let hex = "0123456789ABCDEF";
  if(!data) {
    // starting index
    data = {
      index:0,
      prev_guess:""
    }
  }
  // reply with random char
  viewRequests().forEach(req => {
    replyRequest(req.uid, req.index, hex[Math.random() * 16|0]);
  })
  // assemble guess
  people.forEach(obj => {
    guess[obj.index] = obj.char;
  })
  // change a random char
  if(data) {
    guess[data.index] = hex[Math.random() * 16|0];
    // if we've reached the end
    if (data.index === 31) {
      // start anew
      data.index = -1;
    }
    data.index++;
  }
  // write it to previous guess
  data.prev_guess = guess;
  // cross fingers and guess
  return guess;
}


text:
To exponential digit growth and beyond!
Challenge
Given a base \$1 < b < 10\$ and an index \$t \ge 1\$, output term \$x_t\$, defined as follows:

\$x_1 = 11_{10}\$
\$x_{i+1}\$ is obtained by converting \$x_i\$ to base \$b\$ and then reinterpreting its digits in base \$10\$
Output should be in base \$10\$

A walk through for base 5, term 5 would be:

\$x_1 = 11_{10}\$.
\$11_{10} = 21_{5}\$ so \$x_2 = 21_{10}\$.
\$21_{10} = 41_{5}\$ so \$x_3 = 41_{10}\$.
\$41_{10} = 131_{5}\$ so \$x_4 = 131_{10}\$.
\$131_{10} = 1011_{5}\$ so \$x_5 = 1011_{10}\$.
We output the string "1011" or the integer 1011.

Test Cases
Note: these are one indexed
base 2, term 5 --> 1100100111110011010011100010101000011000101001000100011011011010001111011100010000001000010011100011
base 9, term 70 --> 1202167480887
base 8, term 30 --> 4752456545
base 4, term 13 --> 2123103032103331200023103133211223233322200311320011300320320100312133201303003031113021311200322222332322220300332231220022313031200030333132302313012110123012123010113230200132021023101313232010013102221103203031121232122020233303303303211132313213012222331020133

Notes

Standard loopholes are not allowed
Any default I/O method is allowed
You may use different indexes (such as 0-indexed, 1-indexed, 2-indexed, etc) for \$t\$
You may output the first \$t\$ terms.
As this is code-golf, shortest code wins for that language

Do we have to support larger numbers or just numbers up to 2^31 - 1?

@EmbodimentofIgnorance The maximum of your language (Remember the standard loophole, though!)

Is there a challenge that includes bases > 10? (In that case you would repeatedly interpret 11 as if it was in base b and convert it back to base 10, etc.)

@Neil I didn't include bases higher than 10 since (for example) 4a wouldn't be a valid number in base-10

You wouldn't get 4a, since you'd be interpreting the base 10 digits as base b and converting to base 10 each time (i.e. the other way around from this question).

@Neil Oh, I see. I thought you were suggesting a modification or the like

JavaScript (Node.js), 40 bytes
Thanks to @Neil for saving 5 bytes on this version and 2 bytes on the BigInt version
Takes input as (t)(base), where \$t\$ is 1-indexed.
n=>g=(b,x=11)=>--n?g(b,+x.toString(b)):x

Try it online!

JavaScript (Node.js), 48 bytes (BigInt version)
Takes input as (t)(base), where \$t\$ is 1-indexed. Returns a BigInt.
n=>g=(b,x=11n)=>--n?g(b,BigInt(x.toString(b))):x

Try it online!

Do you need to eval in the first version? + would save 5 bytes...

And BigInt saves two bytes in the second version, because you don't need to add n to the string.

(b,t,x=11)=>--t?f(b,t,+x.toString(b)):x is 1 char shorter

@Qwertiy It's actually 1 byte longer, because we'd need to prepend f= (since the function is referencing itself).

@Arnauld, oops. Then this one n=>b=>g=(x=11n)=>--n?g(BigInt(x.toString(b))):x :) If call f(t)(b)() is allowed.

@Qwertiy I personally don't like it. But the corresponding meta-post seems to have significantly more upvotes than some times ago, so I suppose it should be OK.

05AB1E, 5 bytes
>IF¹B

Try it online!
Explanation
>       # increment <base>
 IF     # <term> times do:
   ¹B   # convert from base-10 to base-<base>

Note that there is no need to explicitly start the sequence at 11.
Starting at base+1 and doing an extra iteration will result in the first iteration giving 11.

Japt, 9 bytes
ÆB=sV n
B

Try it
(Two inputs, U and V)
Æ            Range [0..U)
 B=          For each, set B (B is preinitialized to 11) to
   sV          B's previous value converted to base-V
   n           and back to base-10
B            Print out B's final value

This will never be able to output the first term, will it?

@Shaggy Fixed at the cost of two bytes

Nicely saved :) Wouldn't have thought of doing that meself.

Husk, 7 bytes
!¡odB¹→

Try it online! This version is 2-indexed; it takes the two inputs \$b\$ and \$t\$ as arguments.
Explanation
!¡odB²→²⁰  (Written with explicit arguments; let B and T denote them.)
!       ⁰  Take element T of
 ¡          the function repeatedly applied to
      →²     B + 1:
  o B²       Convert to base B
  od         then convert to decimal.

Wolfram Language (Mathematica), 46 bytes
bNest[FromDigits[#~IntegerDigits~b]&,11,#]&

Try it online!
Call with f[base][t]. 0-indexed.

41 bytes

Python 2, 71 bytes
def f(b,n):h=lambda x:x and x%b+10*h(x/b);return n and h(f(b,n-1))or 11

Try it online!
0-indexed.

Retina, 67 bytes
.+,(\d+)
11,$1*
"$+"{`^\d+
*
)+`(?=_.*,(_+))(\1)*(_*)
$#2*_$.3
,_+

Try it online! Takes comma-separated inputs \$t\$ (0-indexed) and \$b\$. Does all of its calculations in unary so times out for large numbers. Explanation:
.+,(\d+)
11,$1*

Initialise \$x_0=11\$ and convert \$b\$ to unary.
"$+"{`

Repeat \$t\$ times.
^\d+
*

Convert \$x_i\$ to unary.
)+`(?=_.*,(_+))(\1)*(_*)
$#2*_$.3

Convert to base \$b\$.
,_+

Delete \$b\$ from the output.

Clojure, 109 bytes
Credit to MilkyWay90 for removing 10 bytes by spotting unnecessary spaces
Credit to Embodiment of Ignorance for another byte from another unnecessary space
Golfed
(defn f([b t](f b t 11))([b t v](if(= t 1)v(f b(dec t)(read-string(.(new BigInteger(str v))(toString b)))))))

Ungolfed
(defn f
  ([base term] (f base term 11))
  ([base term value] (if (= term 1)
                      value
                      (f base (dec term) (read-string (. (new BigInteger (str value)) (toString base)))))))

I think the main place bytes could be saved is the expression for... reradixing? whatever that would be called. Specifically:
(read-string (. (new BigInteger (str value)) (toString base)))

Do you need those spaces? Can you eliminate spaces?

Didn't even occur to me to remove spaces where they were separating syntactically differentiable things; looks like Clojure is a bit more permissive than I thought. Thank you!

There is still an unnecessary space in (if (= t 1)

Whoop, good catch

93 bytes

Jelly, 8 7 bytes
‘b³Ḍ$⁴¡

Try it online!
A full program that takes \$b\$ as first argument and 1-indexed \$t\$ as its second argument. Returns the integer for the relevant term (and implicitly prints). Uses the observation by @Emigna regarding starting with \$b + 1\$.
Explanation
‘b³Ḍ$⁴¡ | Main link: first argument b, second argument t
‘       | b + 1
    $⁴¡ | Repeat the following t times
 b³     | Convert to base b
   Ḍ    | Convert back from decimal to integer

Explanation for those of us who can't recognize atoms at a quick glance?

C# (Visual C# Interactive Compiler), 87 bytes
n=>m=>{int g=11;for(var s="";m-->0;g=int.Parse(s),s="")for(;g>0;g/=n)s=g%n+s;return g;}

Saved 5 bytes thanks to @KevinCruijssen
Try it online!

87 bytes by changing the do-while into a regular for-loop.

Perl 6, 28 bytes
{(11,+*.base($^b)...*)[$^t]}

Try it online!
The index into the sequence is zero-based.

K (ngn/k), 13 bytes
{y(10/x\)/11}

Try it online!

Pyth, 8 bytes
uijGQTEh

Try it online!

brainfuck, 270 bytes
++<<++<,+++<-[----->-<]<,,[<-----[->++++++++++<]++>[-<+>],]<[>>>>>>[<<<[->>+<<]>>>>>]<<[[>+<-]>>[-[<++++++++++>-]>+>]<[<<]>>[-<<+>>>+<]>>[-[<-[>>+>>]>>[+[-<<+>>]>[-<]<[>]>++>>>]<<<<<-]+>[-<+<+>>]<<[->>+<<]>>>]<[-]<[[-<+>]<<]<]<[->>+<<]<-]>>>>[>>]<<[>-[-----<+>]<----.<<]

Try it online!
0-indexed.  The number of iterations is assumed to be at most 255.
Explanation
The tape is laid out as follows:
num_iterations 0 0 base digit0 0 digit1 0 digit2 ...

Each digit is actually stored as that digit plus 1, with 0 reserved for "no more digits".  During the base conversion, the digits currently being worked on are moved one cell to the right, and the base is moved to the left of the current working area.
++<<++              Initialize initial value 11
<,+++<-[----->-<]   Get single digit as base and subtract 48 to get actual number
<,,[<-----[->++++++++++<]++>[-<+>],]   Read multiple digits as number of iterations
<                   Go to cell containing number of iterations

[                   For each iteration:
  >>>>>>              Go to tens digit cell
  [<<<[->>+<<]>>>>>]  Move base to just before most significant digit
  <<                  Return to most significant digit

  [                   For each digit in number starting at the left (right on tape):
    [>+<-]            Move digit one cell to right (to tell where current digit is later)
    >>[-[<++++++++++>-]>+>]  Multiply each other digit by 10 and move left
    <[<<]>>           Return to base
    [-<<+>>>+<]       Copy base to just before digit (again) and just before next digit to right (left on tape)
    >>[               For each digit at least as significant as this digit:

      -[<-[>>+>>]>>[+[-<<+>>]  Compute "digit" divmod base
      >[-<]<[>]>++    While computing this: add quotient to next digit; initialize digit to "1" (0) first if "0" (null)
      >>>]<<<<<-]     End of divmod routine

      +>[-<+<+>>]     Leave modulo as current digit and restore base
      <<[->>+<<]      Move base to next position
      >>>
    ]

    <[-]<             Delete (now useless) copy of base
    [[-<+>]<<]<       Move digits back to original cells
  ]                   Repeat entire routine for each digit

  <[->>+<<]           Move base to original position
  <-                  Decrement iteration count
]

>>>>[>>]<<[>-[-----<+>]<----.<<]  Output by adding 47 to each cell containing a digit

Charcoal, 14 bytes
≔11ζＦＮ≔⍘ＩζＩηζζ

Try it online! Link is to verbose version of code. Takes inputs as \$t\$ (0-indexed) and \$b\$. Explanation:
≔11ζ

\$x_0=11\$.
ＦＮ

Loop \$b\$ times.
≔⍘ＩζＩηζ

Calculate \$x_i\$.
ζ

Output \$x_t\$.

Pari/GP, 50 bytes
(b,n)->x=11;for(i=2,n,x=fromdigits(digits(x,b)));x

Try it online!

C (gcc), 59 bytes
f(t,b){t=t?c(f(t-1,b),b):11;}c(n,b){n=n?c(n/b,b)*10+n%b:0;}

Try it online!

Groovy, 45 bytes
a,b,c=11->a--?f(a,b,a.toString(c as int,b)):c

Try it online!
Port of @Arnauld's answer

PHP, 83 75 bytes
function c($b,$t,$v=11){return $t==1?$v:c($b,$t-1,base_convert($v,10,$b));}

Try it online!
This one will only work work with "small" numbers (e.g. not test cases 1 and 4)

Japt, 10 bytes
0-indexed. Takes t as the first input, b as the second.
_ìV ì}gBìC

Try it

Gaia, 8 bytes
Bd
11@↑ₓ

Try it online!
Takes 0-based iterations then base.
Bd		| helper function: convert to Base b (implicit) then convert to base 10
		| main function:
11		| push 11
  @		| push # of iterations
   ↑ₓ		| do the above function (helper function) that many times as a monad

Ruby, 39 bytes
Zero-indexed.
->b,n,x=11{n.times{x=x.to_s(b).to_i};x}

Try it online!

Perl 5 -Mbigint -pa, 65 bytes
$\=11;map{$p=$\;$\%=0+"@F";$\=($p%"@F").$\while$p/=0+"@F"}2..<>}{

Try it online!

GolfScript, 16 bytes
11\~{base""*~}+*

Try it online!
The input is t (0-indexed) and then b.
11                 # x_1
  \~               # Parse the inputs to integers
    {base""*~}+    # Add b to the beginning of this block to get {b base""*~}
  {b base""*~}     # This block goes from x_n to x_(n+1)
   b base          # Convert to base b
         ""*       # Join the digits with "" between them
            ~      # Parse it to an integer
               *   # Execute this block t times


text:
Output first \$n\$ digits of \$\pi^{1/\pi}\$
This challenge is to produce the shortest  code for the constant \$\pi^{1/\pi}\$. Your code must output the first \$n\$ consecutive digits of \$\pi^{1/\pi}\$, where \$n\$ is given in the input. Alternatively, your program may accept no input, and output digits indefinitely
This is code golf, so the shortest submission (in bytes) wins except that it must output the 1000 digits for \$n = 1000\$ in less than 10 seconds on a reasonable PC.
You may not use a built-in for \$\pi\$, the gamma function or any  trigonometic functions.
If the input is \$n = 1000\$ then the output should be:
1.439619495847590688336490804973755678698296474456640982233160641890243439489175847819775046598413042034429435933431518691836732951984722119433079301671110102682697604070399426193641233251599869541114696602206159806187886346672286578563675195251197506612632994951137598102148536309069039370150219658973192371016509932874597628176884399500240909395655677358944562363853007642537831293187261467105359527145042168086291313192180728142873804095866545892671050160887161247841159801201214341008864056957496443082304938474506943426362186681975818486755037531745030281824945517346721827951758462729435404003567168481147219101725582782513814164998627344159575816112484930170874421446660340640765307896240719748580796264678391758752657775416033924968325379821891397966642420127047241749775945321987325546370476643421107677192511404620404347945533236034496338423479342775816430095564073314320146986193356277171415551195734877053835347930464808548912190359710144741916773023586353716026553462614686341975282183643

Note the 1000 decimal places includes the first \$1\$.
Output format
Your code can output in any format you wish.
This related question tackles a simpler variant but with the same restrictions.
Notes
If it's helpful, you can assume \$\pi^{1/\pi}\$ is irrational and in fact you can even assume it is a Normal number.

Banning a built-in for pi or trigonometric functions is kind of useless. For example, we can use $\Gamma(1/2)^2$

I'm curious, is this even possible? Could it not be that digit number 1000000 of pi^(1/pi) relies on digit number 1000099?  Or even 9999999, in theory at least..? At some point you'll have ...4599999999999999999999999999999999......, but that could be 4600000000000000000000000000000000..... if your calculations included more digits. I believe it's impossible to say how many more digits is needed..? Or?

@StewieGriffin It's certainly possible but I don't know how quickly you can add a new digit once you have already outputted thousands, say.

Why the restriction on how the digits are output? It adds absolutely nothing to the challenge.

You said that it should print digits forever. Can we assume infinite memory or only infinite time? Do we have to come up with some clever way to calculate the 10^15th digit without using more than a petabyte of memory?

@StewieGriffin It is possible, but the number of digits cannot be known in advance. Instead, it should be computed on the fly, which makes the challenge ¿unnecessarily? complicated

For the record: https://math.stackexchange.com/q/3232906/92515

@StewieGriffin You can assume both infinite memory and time.

I'm not sure that Generally you may not use any built-in that computes pi for you means. If my language has a variable-precision function that takes a string like 'pi' and a number N and symbolically computes N decimals of what the string represents, is that acceptable?

Is ConvertDegreesToRadians(180) interesting enough as a way to produce pi?

How can a [tag:restricted-time] challenge assume infinite time?

@Xcali. The challenge has been edited since it was closed (and now reopened).  In any case, the time is restricted for the n=1000 case.

Is there a way to calculate that number without use pi?

@RosLuP You can compute $\pi$ to enough precision and go from there or try to find a direct way to compute $\pi^{1/\pi}$ without first computing $\pi$. I think both are good.

@StewieGriffin I possible dont know enought but for doing  1.9999999999 cut in the 3th digits after the point result in 1.999 not 2. for result 2 someone has to round (some time the function print the number) the 4 digits. so until no round is done all is ok...

@Rosario What do you get if you do 0.5 - 1e-50? You get 0.500, not 0.499, not even 4.99999999999999. If your calculations show 0.500..., how can you know for certain that it's not 0.499999999999999... How can you know if the first digit after comma should be 4 or 5?

@StewieGriffin  in pi^(1/pi)" 99999999999" in the digits are very rare but if i find a point where there are all these 9 i go with more precise number for find for example 9999999999777 and be sure the cut of the 9 is ok

i do not understand all these downvote to this interesting question

@Rosario, none of the answers do what you describe. A look-ahead solves the problem, but there's no way to know for sure how much look-ahead is needed, thus the algorithm gets quite complex quite fast. In reality it's likely not more than a few digits (if any at all), but we don't know that.

Python, 149 bytes
Saved one byte due to @H.PWiz.
k=n=int(input())+1
i=j=8*n
e=l=p=z=10**n
while i:p=2*z-i//2*p//~i;i-=2
q=z-z*z//p
while j:l=q//j+q*l//z;j-=1
while k:e=z+e*l//k//p;k-=1
print(e//100)

Try it online!
Input n = 1000 finishes in less than 0.5s.
\$\sqrt[\pi]{\pi}\$ is calculated as the \$e^\frac{\ln(\pi)}{\pi}\$.\$\pi\$ is calculated with the usual Euler-Leibniz: \$\pi=\sum_{n=0}\limits^{\infty}{\frac{n!}{(2n+1)!!}}\$.
\$e^x\$ and \$\ln(x)\$ are both computed using a Taylor series: \$e^x=\sum\limits_{n=0}^{\infty}{\frac{x^n}{n!}}\$ and \$\ln(1-x)=-\sum\limits_{n=1}^{\infty}{\frac{x^n}{n}}\$. Because the iteration for \$\ln(x)\$ converges only when \$|x|<1\$, this is instead calculated as \$\ln(\pi)=-\ln(\frac{1}{\pi})\$.
Given that Python uses Karasuba Multiplication, the overall runtime complexity is \$\mathcal{O}(n^{1+\log_2(3)})\$ - in other words, twice as many digits will take approximately 6 times as long.

Subquadratic Complexity
import sys
from gmpy2 import isqrt, mpz

def piks(a, b):
  if a == b:
    if a == 0:
      return (1, 1, 1123)
    p = a*(a*(32*a-48)+22)-3
    q = a*a*a*24893568
    t = 21460*a+1123
    return (p, -q, p*t)
  m = (a+b) >> 1
  p1, q1, t1 = piks(a, m)
  p2, q2, t2 = piks(m+1, b)
  return (p1*p2, q1*q2, q2*t1 + p1*t2)

n = int(sys.argv[1])-1
m = n*20//3
z = mpz(10)**n

# n / log(777924, 10)
pi_terms = mpz(n*0.16975227728583067)

pp, pq, pt = piks(0, pi_terms)
pq *= 3528

pi2m = (pq << m) // pt

a, b = 2 << m, 8
while a != b:
  a, b = (a + b) >> 1, isqrt(a*b)

mlog2_pi = (z << m) // a

a, b = 2*pi2m, 8
while a != b:
  a, b = (a + b) >> 1, isqrt(a*b)
logpi_pi = z * pi2m // a - mlog2_pi

mlog2 = mlog2_pi * pq // pt

d = e = (15044673 << m) // 10450451
pt //= z
while d:
  a, b = 2*e, 8
  while a != b:
    a, b = (a + b) >> 1, isqrt(a*b)
  lnx = (pq * e) // (pt * a) - mlog2
  d = e * (lnx - logpi_pi) // z
  e -= d

print(e * z >> m)

Try it online!
Input n = 20000 finishes in less than one second.
\$\pi\$ can be computed in subquadratic time by use of Karatsuba splitting a.k.a. Fast E-function Evaluation, which reduces a summation to n terms to a single rational value p/q, splitting in binary descent. I've chosen to use Ramanujan #39, which is the fastest converging series of its kind that doesn't require an arbitrary precision square root, to my knowledge. Explicitly, this is computed as:
\$\large{\left.{3528}\middle/{\sum\limits_{n=0}^{\infty}\frac{(-1)^n (4n)! (1123+21460n)}{(n!)^4 14112^{2n}}}\right.}\$
For \$\ln(x)\$ and \$e^x\$, using the same technique wouldn't provide any benefit, because both are computed as a power series of an arbitrary precision variable. Fortunately, Gauss has gifted us with an elegant quadratically converging formula for \$\ln(x)\$, based on the Arithmetic-Geometric Mean:
\$\DeclareMathOperator{\AGM}{AGM}\large\ln(x)=\lim\limits_{n\rightarrow\infty}\frac{\pi x^n}{2n\AGM(x^n,4)}\$
or, in cases when large powers of x are inconvenient, this can also be computed as:
\$\large\ln(x)\approx\frac{\pi x 2^m}{2\AGM(x 2^m,4)}-m\log(2)\$
Conveniently, division by \$\pi\$ can be acheived simply by not multiplying through by \$\pi\$.
With the natural logarithm thusly defined, \$e^\frac{\ln(\pi)}{\pi}\$ can be computed via Newton's method on \$x_{n+1}=x_n-x_n(\ln(x_n)-\frac{\ln(\pi)}{\pi})\$. The overall complexity is then \$\mathcal{O}(n^*\log^3(n))\$, where \$n^*\$ will vary with the complexity of the multiplication algorithm GMP is using for any given bit length.

This is very nice!

-1

What a great update!

Wolfram Language (Mathematica), 62 bytes
In my first try I used Zeta function but this one uses the imaginary part of ln(-1) for pi. (@someone)
Prints more than 4000 digits in the first 10 seconds,
q=Im@Log@-1;Do[Print@RealDigits[N[q^(1/q),2k]][[1,k]],{k,∞}]

Try it online!
9 bytes saved from @someone

I was hoping they might all be printed on the same line so the first 1000 digits look like the example I gave in the question.

@Anush I can print digits for ever or give you any number of digits (but then it should stop). You must decide

Your code should print digits forever. I just meant they should be printed horizontally and not vertically.

This is the first time you are saying that. The question does not ask that.

Apologies. I have clarified the question now.

it is highly recommended that you don't change the rules of a challenge after even one answer is submitted. I would suggest you to use sandbox next time.

For some reason I have never seen anyone use non-printable ASCII chars in Wolfram answers here, but if we assume Wolfram is "the language that TIO calls Wolfram and interprets", this seems to work for 68 bytes: Try it online!

That previous golf actually was for 66 bytes; I mistyped things and realized that after 5 minutes since the comment. You can also save several bytes by using Im@Log@-1 for pi (as $ln(-1) = i \pi$)

I now allow any output format.

Calculate the digit in a different way to save several bytes; assuming I did not produce any mistakes. Try it online!

Now you can output the first n digits, allowing you to save several bytes. q^(1/q) -> q^q^-1 to save one byte as well.

Save a byte by using Log@-1/I for pi.

Wolfram Language (Mathematica), 23 22 bytes
(p=Log@-1/I)^p^-1~N~#&

Try it online!
-1 byte by @someone — the use and reuse of p beats the pure function
Taking a lot of inspiration from @J42161217 and displaying n digits instead of an infinite stream.
Note that I'm using ToString in Tio to suppress the trailing precision specifier in the output, which does not appear when this code is executed in Mathematica.
Maybe using 180° for pi would work; but maybe that's too close to being trigonometric and is disallowed.

22 bytes

AXIOM, 221 bytes
m(k)==(v:=8.*k;(4/(v+1)-2/(v+4)-1/(v+5)-1/(v+6))*16^-k)
p(n:PI):String==(d:=digits(n+9);e:=10.^-digits();i:=s:=0;repeat(k:=m(i);k<e=>break;s:=s+k;i:=i+1);r:=concat split((s^(1/s))::String,char " ");digits(d);r.(1..(n+1)))

test and ungolf:
(3) -> p 1000
   (3)
  "1.43961949584759068833649080497375567869829647445664098223316064189024343948
  91758478197750465984130420344294359334315186918367329519847221194330793016711
  10102682697604070399426193641233251599869541114696602206159806187886346672286
  57856367519525119750661263299495113759810214853630906903937015021965897319237
  10165099328745976281768843995002409093956556773589445623638530076425378312931
  87261467105359527145042168086291313192180728142873804095866545892671050160887
  16124784115980120121434100886405695749644308230493847450694342636218668197581
  84867550375317450302818249455173467218279517584627294354040035671684811472191
  01725582782513814164998627344159575816112484930170874421446660340640765307896
  24071974858079626467839175875265777541603392496832537982189139796664242012704
  72417497759453219873255463704766434211076771925114046204043479455332360344963
  38423479342775816430095564073314320146986193356277171415551195734877053835347
  93046480854891219035971014474191677302358635371602655346261468634197528218364
  3"
                                                             Type: String
           Time: 0.03 (IN) + 0.53 (EV) + 0.25 (OT) + 0.15 (GC) = 0.97 sec

-- Bailey-Borwein-Plouffe formula for pi
-- https://en.m.wikipedia.org/wiki/Bailey%E2%80%93Borwein%E2%80%93Plouffe_formula
--       +oo
--      -----          --                                      --
--      \          1   |     4         2         1         1    |
--   pi= |      -------|  ------- - ------- - ------- - ------- |
--      /            k |   8*k+1     8*k+4     8*k+5     8*k+6  |
--      ----- k   16   --                                      --
--        0
m(k)==(v:=8.*k;(4/(v+1)-2/(v+4)-1/(v+5)-1/(v+6))*16^-k)
p(n:PI):String==
      d:=digits(n+9); e:=10.^-digits(); i:=s:=0
      repeat
          k:=m(i)
          k<e=>break
          s:=s+k;i:=i+1
      r:=concat split((s^(1/s))::String,char " ")
      digits(d)
      r.(1..(n+1))

the function m calculate the term of the sum; the p() function loop, sum them in the variable s until the term is < than min float value (one can see as epsilon);
p() function return one string of that number pi^(1/pi); it seems the required digits are returned in less than 1 second for input to p() function 1000.

APL(NARS), 114 chars
r←Q w;m;i;d;e;k;⎕FPC
⎕FPC←4×w+←8⋄m←i←0v⋄e←÷10v*w
k←1+8×i⋄m+←d←(+/4 2 1 1÷k,-k+3..5)÷16*i⋄i+←1⋄→2×⍳e<∣d⋄r←¯9↓w⍕m*÷m

If it is allowed to use one function that can return π my solution is
APL(NARS), 27 chars
{⎕FPC←5×⍵+←8⋄¯9↓⍵⍕r*÷r←○1x}

Because function for show the number make the rounding, it is possible one error in the last
digits. But for happen that there would be the number 99999999 in the digits before where to cut
test
  990↓Q 1000
975282183643
  Q 90
1.43961949584759068833649080497375567869829647445664098223316064189024343948917584781977504
  Q 91
1.439619495847590688336490804973755678698296474456640982233160641890243439489175847819775046
  ⎕FPC
128

note that ⎕FPC is not changed outside the function f.

383.322=126,... so 128    913.322=302,... so it FPC doesnt change

APL(NARS), 159 chars
r←Q w;m;i;d;e;k;⎕FPC
⎕FPC←4×w⋄m←i←0v⋄e←÷10v*w
k←1+8×i⋄m+←d←(+/4 2 1 1÷k,-k+3..5)÷16*i⋄i+←1⋄→2×⍳e<∣d⋄r←m*÷m

D←{k←{m←⍵⍕Q⍵⋄'123'∊⍨m[≢m]:⍵⋄∇⍵+1}⍵⋄⍵-←1⋄(⍵-k)↓k⍕Q k}

This would be the bullet proof solution...
Q w function would calculate the number π^(1/π) enough for have w digits after point.
{m←⍵⍕Q⍵⋄'123'∊⍨m[≢m]:⍵⋄∇⍵+1} w function would calculate the number z≥w in the way the last
printed digits in z⍕Q z is in the set '123'. If it is in that set than the string result in z⍕Q z has to be right the digits in position
..w..(z-1)
D w function would cut in the right point w-1 from the string z⍕Q z
  D 90
1.439619495847590688336490804973755678698296474456640982233160641890
  24343948917584781977504
  D 91
1.439619495847590688336490804973755678698296474456640982233160641890
  243439489175847819775046
  990↓D 1000
975282183643

In my opinion if r is the input and P it is as ⍕ but not use any round, (r-1)P Q r
return always the right result. If i make it wrong this is the P function, you show I'm wrong
r←a P w;⎕ct;s;y;k;b
   ⎕ct←0⋄s←''⋄→B×⍳∼w<0⋄s←'¯'⋄w←-w
B: y←⌊w×10x*a⋄b←''
C: b,←10∣y⋄→C×⍳0<y←⌊y÷10⋄k←≢r←⎕D[1+⌽b]⋄→D×⍳∼a=0⋄r←s,r⋄→0
D: →F×⍳∼0≥y←k-a⋄r←s,'0.',('0'⍴⍨-y),r⋄→0
F: r←s,(y↑r),'.',y↓r


text:
Sliding retrieval
Thanks, Uncle (the story)
My slightly mad uncle recently left for the space colonies, and passed his pallet goods business to me. The rectangular warehouse is full of pallets of goods except for the one square by the door, and I've just received the first list of pallets ordered by customers to be sent out today.
Fortunately I have a carefully written map of where each pallet is, and my mad uncle engineered several mini robots which can move a pallet into an adjacent space, much like a sliding 15-puzzle. I don't care where the pallets end up, though, I just want the pallets on the list to arrive in order by the door.
The question is, what series of commands must I give the robots in order to retrieve the required pallets?
The challenge
Given

the size of the grid (rows, cols)
a list of pallets (by their current location) to retrieve in order

You must output a list of grid positions corresponding to which position is to be moved, and which direction. If there is only 1 direction available you may optionally omit that. The pallets will be removed immediately upon arrival by the door (at one corner, index N in the examples).
Worked example
01 02   label the contents  A B
03 04                       C D
05[  ]                      E _

Request: 03 (contents is C)

Command 0: 04
D moves into the (only) adjacent space at index 06
Result: A B
        C _
        E D

Command 1: 03
C moves into the (only) adjacent space at index 04
Result: A B
        _ C
        E D

Command 2: 05
        A B
        E C
        _ D
Command 3: 06
        A B
        E C
        D _
Command 4: 04
        A B
        E _
        D[C]
(C removed having arrived by the door)

Limits and freedoms

Maximum grid size is 100x100
Challenge is code-golf
Solution must execute within 2 minutes on some real-world machine
You can choose your indexing, command syntax, input structures and so on, as long as it's consistent.
I've chosen to use the grid locations for the commands, but conceivably you could emit the value in the element instead (plus a direction) as they are unique.
If you wanted to make an animation of the state (especially for a large grid), I'm sure that would be entertaining!

Examples
A: 3x2, 1 pallet
01  02
03  04
05 [__]

Request: pallet at 03

Valid solution: 05,03,04,06,05

This leaves the following state:

01  02
04  05
__ [03]

B: 15-puzzle, 1 box
01 02 03 04 05
06 07 08 09 10
11 12 13 14[  ]

Request: box 01

Valid solution: 14,13,12,11,06,01,02,07,12,11,06,07,12,11,06,07,08,13,12,11,06,07,08,09,14,13,08,09,10,15,14

02 07 03 04 05
08 12 13 10 14
06 11 09 __[01]

C: 3x2, 4 boxes
01 02
03 04
05[  ]

Request: 02,04,01,05

Valid solution: 04,02,01,03,05,06,04,05,02,06,03S,05E
Pallet taken at:                    ^  ^     ^       ^

Indicating directions with NSEW

Final state:

03 __
__ __
__ __

D: 10x10, 2 boxes
10x10, request boxes at 13,12 (row 1, cols 2 & 1 with 0-index)

Valid solution: (90,80..20, 19,18..12, 22,32..92, 93,94..100) x 15, 90.

E: 4x1, all
4x1: 01 02 03 [ ]
Req: 03,02,01 (only valid order)
Optimal solution: 03,02,03E,01,02E,03E

F: 100x100, 3 near the door
100x100
Req: 9900,9899,9898
Result: 9000,9989,9000S,9898,9898E,9000S

Sandbox link

if boxes 2 and 3 are requested, is it illegal for 3 to pass by the door while you are moving 2 toward the door?

@Jonah: No, or none of the scenarios would be solvable unless the first box was n-1 or n-c. The only thing special about the space by the door is that when the next pallet on the list arrives there, it is immediately removed by my eccentric forklift operator.

JavaScript (Node.js) - 425 424 420 395
(n,m,L)=>(s=Math.sign,G=[...Array(n*m).keys()],i=k=n*m-1,G[k]=-1,R=[],M=j=>{-G[j]-1&&R.push([j,i]);[G[i],G[j]]=[G[j],G[i]];i=j},X=j=>{while(i%n-j%n)M(i+s(j%n-i%n))},Y=j=>{while(y(i)-y(j))M(i+n*s(y(j)-y(i)))},y=i=>(i-i%n)/n,L.map(e=>{J=()=>j=G.indexOf(e);while(J()%n-n+1){m>1&&y(j)-y(i)||M(y(i)?i-n:i+n);X(j+1);Y(j);M(j);m<2?i=k:0}while(J()+1-n*m){X(n-2);Y(j+n);X(n-1);M(j);n<2?i=k:0}G[k]=-1}),R)

Try it online!
Takes n,m and an array of pallets, returns a list of commands where each command is a 2-element array of the location of the pallet to move and the location of the space to move it to.
There's probably a better strategy than what I used, but posting as is for now.