[Question]
  [
You are to write a program which generates random integers between \$0\$ and \$99\$ inclusive, outputting each integer in turn, until \$0\$ is generated. You may choose which single-order random distribution (uniform, binomial, Poisson etc.) you use so long as each integer has a non-zero chance of being generated and is chosen independently. The output should always end with `0`. As each integer must be chosen independently, the output cannot be some permutation of the integers \$\{0, 1, 2, ..., 99\}\$ trimmed to end with \$0\$.
You may follow another method to accomplish the same task, so long as the result is identical to the described method here (for example: you may generate a number \$K\$ geometrically distributed with parameter \$\frac 1 {99}\$, then output \$K\$ independent numbers with a uniform distribution on the set \$\{1, 2, ..., 99\}\$, then output a \$0\$).
The integers may be separated by any non-digit, non-empty separator (e.g. newlines, spaces etc.), and may be output in any consistent base. You may output in any [convenient method](https://codegolf.meta.stackexchange.com/questions/2447/default-for-code-golf-input-output-methods) or [format](https://codegolf.meta.stackexchange.com/q/9501/66833).
This is [code-golf](/questions/tagged/code-golf "show questions tagged 'code-golf'") so the shortest code in bytes wins.
  
[Answer]
# [Scratch 3.0](https://scratch.mit.edu), 9 blocks/76 bytes
[![beautiful](https://i.stack.imgur.com/6XofW.png)](https://i.stack.imgur.com/6XofW.png)
As SB Syntax:
```
define
set[N v]to(1
repeat until<(N)=(0
set[N v]to(pick random(0)to(99
say(N
```
[Try it on Scratch](https://scratch.mit.edu/projects/480455636/)
It just wouldn't be right if I didn't golf this in scratch. This is a function that achieves the desired result
## Explained
```
define                             // Create a function with no name (not a lambda)
set[N v]to(1                       // Initalise the variable we will use to generate random numbers with
                                   // If we didn't set it to 1, the next loop wouldn't start, as it would see that N = 0.
repeat until<(N)=(0                // Pretty self-explanatory
set[N v]to(pick random(0)to(99     // Also pretty self-explanatory. But putting this here means we don't have to include two calls to this block: we've essentially created a post-test loop instead of a pre-test loop
say(N                              // Output the randomly generated number and repeat
```
[Answer]
# [Python 3](https://docs.python.org/3/), 58 bytes
```
from random import*
print(*iter(lambda:randint(0,99),0),0)
```
[Try it online!](https://tio.run/##K6gsycjPM/7/P60oP1ehKDEvBUhl5hbkF5VocRUUZeaVaGhllqQWaeQk5ialJFqBVIAEDXQsLTV1DEDo/38A "Python 3 ‚Äì Try It Online")
[Answer]
# [R](https://www.r-project.org/), 25 bytes
```
c(sample(99,rexp(1),T),0)
```
[Try it online!](https://tio.run/##dcwxCsAgDADA3Ve4mYCDjvqOfiBICoLaoBbs620/0PWG63snGFSlMIRgOy8Bj/ZA63AnmmBUZ2Ga2junZ648olIG1SCR8oCPn9vzbmnmq8HC3w33Cw "R ‚Äì Try It Online")
p(0) at each iteration is (e-1)/e.  
p(each other number) at each iteration is (1/e)\*(1/99).
Obviously this choice of random distribution gives a rather unsatisfying-looking output (since most of the runs are rather short). So [this link](https://tio.run/##fcwxCsAgDADA3Ve4NYFQdNR39AMiKQhqg1qwr7d9Qdcbrq0VoYcimcE5ajwFLO3GIh1IBlcMAzbVWDgMbY3RIxXuXqkNVQ8i@QHrP6fzrnGkq8LE3xHXCw) uses the same approach, but changes p(0) to roughly 0.01 to illustrate some longer runs...
**What's going on?**
```
            rexp(1)         # First determine where the '0' will occur:
                            # We generate a single random number using
                            # an exponential distribution with a
                            # rate parameter equal to 1
                            # (so the chance of any value x is e^-x).  
c(                    ,0)   # Now place '0' at the subsequent position, 
  sample(99,rexp(1),T)      # and fill all the previous positions with
                            # numbers sampled from 1 to 99,
                            # with replacement (specified by the 'T' for TRUE).  
```
[Answer]
# [Random Brainfuck](https://github.com/TryItOnline/brainfuck), ~~67~~ ~~66~~ ~~65~~ 49 bytes
```
+[>>-[>++<-----]>--<?[>->+<[>]>[<+>-]<<[<]>-]>>.]
```
[Try it online!](https://tio.run/##FcnBCYBAEAPAgpZYQYiFhH2ciiDiCQfWv@p8Z7S@3ReW0Y6@P@tZFZZgRRC/FMDZgoJWygwhSfOblKasegE "Random Brainfuck ‚Äì Try It Online")
Finally found a use for this silly variant.
Assumes wrapping cells and that the tape will never overflow (which would be statistically improbable).
Basically, Random Brainfuck is just normal Brainfuck, except it adds the `?` opcode which reads a byte from `/dev/urandom`.
All I have to do is modulo 100.
I move forward 6 bytes each iteration.
Outputs random **bytes** to stdout.
```
+                             (1) 0 0 0 0
[ do
    # advance tape two places for sentinel
    >>                        0 (0) 0 0
    # set 100
    # https://esolangs.org/wiki/Brainfuck_constants#100
    -[>++<-----]>--           0 0 0 (100) 0
    # Read random byte
    <?                        0 (rng) 100 0
    # mod 100
    # https://esolangs.org/wiki/Brainfuck_algorithms#Modulus_algorithm
    [>->+<[>]>[<+>-]<<[<]>-]  0 (0) * rng % 100
    # move left and print
    >>                        0 0 * (rng % 100) 
    .                         print
] while rng % 100 != zero     note: start
```
The equivalent C algorithm:
```
void print_random(void)
{
    uint8_t rng;
    do {
        rng = randbyte() % 100;
        putchar(rng);
    } while (rng != 0);
}
```
[Answer]
# [Ruby](https://www.ruby-lang.org/), ~~19~~ 18 bytes
-1 byte thanks to [Dingus](https://codegolf.stackexchange.com/users/92901/dingus)!
```
loop{1/p(rand~99)}
```
[Try it online!](https://tio.run/##KypNqvz/Pyc/v6DaUL9AoygxL6XO0lKz9v9/AA "Ruby ‚Äì Try It Online")
`rand~99` generates a random integer below `abs(~99)=abs(-100)=100`, `p` prints it to the output and returns the integer as a function and `1/x` fails for `x==0`, stopping the program.
[Answer]
# [R](https://www.r-project.org/), ~~30~~ 29 bytes
```
while(print(sample(0:99,1)))T
```
[Try it online!](https://tio.run/##K/r/vzwjMydVo6AoM69EozgxtwDIMbCytNQx1NTUDPn/HwA "R ‚Äì Try It Online")
`print` returns its argument invisibly, so this will choose an integer from 0-99 uniformly at random until a `0` is printed, because `0` is falsey in R.
Uses the "do-`while`" [tip](https://codegolf.stackexchange.com/a/157131/67312).
Thanks to Robin Ryder for saving a byte.
[Answer]
# [MathGolf](https://github.com/maxbergmark/mathgolf/blob/master/math_golf.txt), 5 [bytes](https://github.com/maxbergmark/mathgolf/blob/master/code_page.py)
```
‚ôÄ(wo‚ñ≤
```
[Try it online.](https://tio.run/##y00syUjPz0n7///RzAaN8vxH0zb9/w8A)
**Explanation:**
```
    ‚ñ≤  # Do-while true (!=0) with pop,
       # using the entire program implicitly as inner code-block:
‚ôÄ      #  Push 100
 (     #  Decrease it to 99
  w    #  Pop and push a random integer within the range [0,99]
   o   #  Print it with trailing newline (without popping)
```
[Answer]
# [Python 3.8](https://docs.python.org/3.8/), ~~52~~ 50 bytes
-2 bytes inspired by [EasyasPi's answer](https://codegolf.stackexchange.com/a/218184/64121).
Produces some integers with probability \$\frac 2 {256}\$ and some with probability \$\frac 3 {256}\$ in each iteration.
```
import os
while id:print(id:=os.urandom(1)[0]%100)
```
[Try it online!](https://tio.run/##K6gsycjPM7YoKPr/PzO3IL@oRCG/mKs8IzMnVSEzxaqgKDOvRAPIsM0v1istSsxLyc/VMNSMNohVNTQw0Pz/HwA "Python 3.8 (pre-release) ‚Äì Try It Online")
Uses the builtin function `id` to avoid assigning a new variable before the loop.  
[`os.urandom(size)`](https://docs.python.org/3/library/os.html#os.urandom) returns a `bytes` object with `size` random bytes. The `bytes` object behaves quite similar to a list of integers, which means `os.urandom(1)[0]` gives a single random integer from \$[0,255]\$, which we map to an integer from \$[0,99]\$ with a modulo operation.
---
# [Python 3.8](https://docs.python.org/3.8/), 53 bytes
Generates integers from a uniform distribution over \$[0, 99]\$.
```
from random import*
while id:print(id:=randint(0,99))
```
[Try it online!](https://tio.run/##K6gsycjPM7YoKPr/P60oP1ehKDEvBUhl5hbkF5VocZVnZOakKmSmWBUUZeaVaAAZtiAVILaBjqWlpub//wA "Python 3.8 (pre-release) ‚Äì Try It Online")
[Answer]
# Batch, 48 bytes
```
@set n=%random:~-2%
@echo %n%
@if %n% gtr 0 %0
```
Works by taking the random number as a string and extracting the last two digits. (But the comparison is a numeric comparison so 00 still compares equal to 0.) 50 bytes if leading zeros are not allowed:
```
@set/an=%random%%%100
@echo %n%
@if %n% gtr 0 %0
```
[Answer]
# [Bash (coreutils)](https://www.gnu.org/software/bash/), 22 bytes
```
shuf -ri0-99|sed /^0/q
```
[Try it online!](https://tio.run/##S0oszvj/vzijNE1BtyjTQNfSsqY4NUVBP85Av/D/fwA "Bash ‚Äì Try It Online")
Bash is amazingly short here.
Using the little-known sed `q` (quit) command.
[Answer]
# [PowerShell](https://github.com/TryItOnline/TioSetup/wiki/Powershell), 24 bytes
```
for(;$x=random 100){$x}0
```
[Try it online!](https://tio.run/##K8gvTy0qzkjNyfn/Py2/SMNapcK2KDEvJT9XwdDAQLNapaLW4P9/AA "PowerShell ‚Äì Try It Online")
[Answer]
# [Pyth](https://github.com/isaacg1/pyth), 6 bytes
```
W
O100
```
[Try it online!](https://tio.run/##K6gsyfj/P5zL39DA4P9/AA "Pyth ‚Äì Try It Online")
---
Python 3 translation:
```
from random import randrange
def n(b):
    print(b)
    return b
while n(randrange(100)):
    pass
```
[Answer]
# x86-16 DOS .COM file, ~~15~~ 10 bytes
Machine code:
```
00000000: 0f c7 f0 d4 64 cd 29 75 f7 c3                    ....d.)u..
```
Assembly:
```
        // sed -i -e 's#//#;#g' dosrand.asm
        // nasm -f bin dosrand.asm -o dosrand.com
        [bits 16]
        org 100h
        section .text
start:
.loop:
        // don't mind the completely non-suspicious AVX instruction
        // ax -> rand()
        rdrand  ax
        // al -> al % 100
        // ah -> al / 100
        // set flags on al
        aam     100
        // putchar(al)
        int     29h
        // Loop if aam didn't return zero
        jnz     .loop
.end:
        // return to dos (jumps to 0000h which is int 20h)
        ret
```
[Try it online!](https://tio.run/##XU7LDoIwELzzFZt4hiCe5Bv8B7OUAjXbR9qSFD/eysO06h52sjOT2UHnuOxoKUfGYiWU53R3i/IYQGlj@SBCUY2kOwKJQhXbamN1I61NW8BnbG9R9QAYEoUodzzXdeJO4IScCT2H9RM01ylJZnbT8HNtyL8CGRIdmmcT2uzVBv69K5fDHuq541E6d@Y@xhcbCEcXS3lp3g) (`int 29h` simulated with `pushf/popf` and `putchar`)
[This binary needs a 2013 processor running a 1981 operating system](https://tvtropes.org/pmwiki/pmwiki.php/Main/AnachronismStew). Nothing weird here. üòõ
Specifically, it requires [the `rdrand` instruction](https://www.felixcloutier.com/x86/rdrand) introduced in Ivy Bridge. However, QEMU supports this even on non-x86 hosts with `-cpu max`.
Prints raw bytes to stdout.
I might make a version for i386 using `printf` later, but I like this meme better.
Thanks to 2x-1 for recommending `int 29h` and saving 5 bytes!
Note that a solution using `mov al, 100; out 41h, al; in al, 41h` was suggested for a portable alternative, but I was unable to get it to work properly; they either infinite looped or the data wasn't random enough depending on the DOS implementation I used (NTVDMx64, DOSBOX, and QEMU/FreeDOS).
[Answer]
# [Raku](https://github.com/nxadm/rakudo-pkg), 19 bytes
```
{{100.rand+|0}...0}
```
[Try it online!](https://tio.run/##K0gtyjH7n1upoJamYPu/utrQwECvKDEvRbvGoFZPT8@g9n9BaYlC2n8A "Perl 6 ‚Äì Try It Online")
[Answer]
# [Java (JDK)](http://jdk.java.net/), 61 bytes (recursive)
```
Object f(){int r=100;return(r*=Math.random())<1?r:r+" "+f();}
```
[Try it online!](https://tio.run/##JY3BCsIwEETv/YrFU6IY2qtR/ILiwaN4SNOqG9ukbDaClH57DDi3YZj3nPmYvevfGac5EIMrXSXGUT2St4zBq62u7GhihNagh6WKbBhtvnRusAwPIRf0DHRq6lrTwIm8oO2pNfxSZHwfJiHlsTnTgXYb2OzKQa8ZYE7diBb@NPgE7GEqAnFlQv@83cHQM8rig5LrN/IwqZBYzWXm0YvCkbqMa7XmHw "Java (JDK) ‚Äì Try It Online")
```
Object f(){         // Method returning an Object because it either returns an Integer or a String. 
 int r=100;         // Initialize r as an int(eger) to 100.
 return             // The rest can be inlined, so use the return here.
  (
   r*=Math.random() // Multiply 100 by a random double number in range [0,1).
                    // Also, *= is a compound operator that implies a cast,
                    // therefore changing the double to an int at no cost.
                    // So now, r is an integer in range [0,100).
  )<1?              // If the multiplied number is zero (the only possible value below 1)
    r               // Return r as an int, which is automatically boxed to an Integer.
                    // Technically, r is 0, so I could have written 0 instead of r
                    // This is the recursion-closing branch.
   :                // Otherwise
    r+" "+f();      // Return a String, composed of r, a space and the result of the next call to f()
                    // which may either be another String or 0.
}
```
# Java (JDK), 64 bytes (iterative)
```
v->{for(int r=1;r>0;System.out.println(r*=Math.random()))r=100;}
```
[Try it online!](https://tio.run/##HYyxisMwEER7f8WWUiDCqXV2c3WqQJqQYk@2c/JJK7NaGY7gb3eUVMPMPN6MKx7n4W/3cUksMNduivhgpkJOfCJzsI0LmDOc0RM8G4Cl/ATvIAtKjTX5AWL91EXY0@N2B@RH1h8U4DtRLnHkr2vlepi6fT32zymx8iTA3cly39rLf5YxmlTELFUigRQfujPKr2GkIUWlta5w29pttx/xZNC5cRFFJQT93rZm218 "Java (JDK) ‚Äì Try It Online")
## Credits
* -2 bytes thanks to [Kevin Cruijssen](https://codegolf.stackexchange.com/users/52210/kevin-cruijssen) on the iterative version
[Answer]
# [Retina](https://github.com/m-ender/retina/wiki/The-Language), 25 bytes
```
./^0/^{L$`^
99*
\L@$`
$.`
```
[Try it online!](https://tio.run/##K0otycxLNPz/X08/zkA/rtpHJSGOy9JSiyvGx0ElgUtFL@H/fwA "Retina ‚Äì Try It Online") Explanation:
```
.
```
Suppress the default output.
```
/^0/^{
```
Repeat until the value is zero.
```
L$`^
99*
```
Replace the value with 99 `_`s.
```
\L@$`
$.`
```
Take the length of a random prefix and also output it on its own line.
[Answer]
# [Factor](https://factorcode.org/), 29 bytes
-4 bytes thanks to @Bubbler.
```
[ 100 random dup . 0 > ] loop
```
[Try it online!](https://tio.run/##S0tMLskv@h8a7OnnbqWQnVqUl5qjkJtYkqFQlJiXkp@rUFCUWlJSWVCUmVeiYP0/WsHQwAAmlVJaoKCnYKBgpxCrkJOfX/D/PwA "Factor ‚Äì Try It Online")
[Answer]
# [Phooey](https://github.com/ConorOBrien-Foxx/Phooey), 9 bytes
```
(&~r99$c)
```
[Try it online!](https://tio.run/##K8jIz0@t/P9fQ62uyNJSJVnz/38A "Phooey ‚Äì Try It Online")
Dumps raw bytes to stdout.
```
(      do
  &      set cell to 0 by popping from empty stack
  ~r99   generate random from cell to 99
  $c     print as byte
)      while cell is nonzero
```
# Phooey, integer output, 12 bytes
```
(&~r99$i" ")
```
[Try it online!](https://tio.run/##K8jIz0@t/P9fQ62uyNJSJVNJQUnz/38A)
Does the same thing, only instead of printing as a raw byte, it prints it as an integer and adds a space.
[Answer]
## Javascript (V8), 39 bytes
-4 bytes thanks to [Redwolf Programs](https://codegolf.stackexchange.com/users/79857/redwolf-programs) and [aaaidan](https://codegolf.stackexchange.com/users/51510/aaaidan).
```
do print(a=Math.random()*99|0);while(a)
```
---
## Javascript (V8), ~~45~~ 43 bytes
-2 bytes thanks to [EasyasPi](https://codegolf.stackexchange.com/users/94093/easyaspi).
```
do{a=~~(Math.random()*99);print(a)}while(a)
```
```
do {
  a = ~~ (Math.random()*99);
  print(a)
} while(a)
```
Uses a double bitwise NOT operator (~), as a [substitute for Math.floor](http://rocha.la/JavaScript-bitwise-operators-in-practice).
[Try it online!](https://tio.run/##y0osSyxOLsosKNEts/j/PyW/OtG2rk7DN7EkQ68oMS8lP1dDU8vSUtO6oCgzr0QjUbO2PCMzJ1Uj0c5A8/9/AA "JavaScript (V8) ‚Äì Try It Online")
[Answer]
# [Random Brainfuck](https://github.com/TryItOnline/brainfuck), 37 bytes
```
+[>-[>++<-----]>--[->?[<<+>>[-]]<]<.]
```
[Try it online!](https://tio.run/##FcHRCYAwEAPQgY44wREHCfmoiiDSCgXnP/G92cbxdGyzXeN897sqRIgRiZ8JCFyVGaRgp3NxVX0 "Random Brainfuck ‚Äì Try It Online")
This answer is inspired by EasyasPi's solution, but I am avoiding modulo by not even trying to get a uniform distribution.
This theoretically should work, but practically will take a long time to finish.
If you change the code setting the cell to 100 to a lower number you will see that it indeed terminates at some point.
```
+                          ; initialise cell[0] with 1
[  
    >                      ; make cell[1] the new cell[0]
    -[>++<-----]           ; set cell[1] to 100
    >--                 
        [->?[<<+>>[-]]<]   ; 100 times increment cell[0] with some probability
    <
    .                      ; print cell[0] 
]                          ; until cell[0] is 0
```
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), 8 bytes
```
¬≥X‚Äô+∆≤∆¨I;
```
[Try it online!](https://tio.run/##y0rNyan8///Q5ohHDTO1j206tsbT@v9/AA "Jelly ‚Äì Try It Online")
## Explanation
```
¬≥X‚Äô+∆≤∆¨I;   Main niladic link
     ∆¨     Repeat and collect results until there's a duplicate result
    ∆≤      (
¬≥            100
 X           Choose a random number from 1 to 100
  ‚Äô          Decrement (to get a number from 0 to 99)
   +         Add to the current value
    ∆≤      )
      I    Increments (deltas)
       ;   Join with the implicit argument, 0
```
[Answer]
# [APL (Dyalog Unicode)](https://www.dyalog.com/), ~~15 11 10 33~~ 16 bytes
```
100,‚àò?‚ç®‚ç£{0=‚äÉ‚åΩ‚ç∫}‚ç¨
```
[Try it online!](https://tio.run/##SyzI0U2pTMzJT///qG@qp/@jtgkGXI862tP@GxoY6DzqmGH/qHfFo97F1Qa2j7qaH/XsfdS7q/ZR75r/QDX/0wA "APL (Dyalog Unicode) ‚Äì Try It Online")
A full program which outputs the numbers separated by spaces.
Uses `‚éïIO‚Üê0` (0-indexing).
-4 then -1 byte from Ad√°m.
-19 bytes from 1\_am\_Jack.
[Answer]
# [05AB1E](https://github.com/Adriandmen/05AB1E/wiki/Commands), 8 [bytes](https://github.com/Adriandmen/05AB1E/wiki/Codepage)
```
[99√ùŒ©=_#
```
[Try it online.](https://tio.run/##yy9OTMpM/f8/2tLy8NxzK23jlf//BwA)
**Explanation:**
```
[         # Start an infinite loop:
 99√ù      #  Push a list in the range [0,99]
    Œ©     #  Pop and push a random integer from this list
     =    #  Print it with trailing newline (without popping)
      _   #  Pop and if this integer is 0:
       #  #   Stop the infinite loop
```
[Answer]
# [CJam](https://sourceforge.net/p/cjam), ~~10~~ 9 bytes
```
{S100mr}h
```
[**Try it online!**](https://tio.run/##S85KzP3/vzrY0MAgt6g24/9/AA)
Prints each number with a space before it.
### How it works
```
{       }h    e# Do-while loop, withput consuming the condition. Nonzero is truthy
 S            e# Push space      
  100         e# Push 100
      mr      e# Random integer with uniform distribution on [0 1 2 ... 99]
              e# Implicit output
```
[Answer]
# [C (gcc)](https://gcc.gnu.org/), ~~59~~ \$\cdots\$ ~~44~~ 42 bytes
Saved 2 bytes thanks to [dingledooper](https://codegolf.stackexchange.com/users/88546/dingledooper)!!!  
Saved a byte thanks to [Davide](https://codegolf.stackexchange.com/users/100356/davide)!!!
```
f(i){for(;printf("%d ",i=rand()%100),i;);}
```
[Try it online!](https://tio.run/##TY3BCsIwEETv@YolUNilLSTn2D/xEtKkLNRYUkGh5NeNsVZxTjNvZ1jXT86VEpBpC9eEZkkcbwFlM4LseEg2jkiNVoo6NmRyqWe4WI5IYhNQVWeAb8px9A8YQJnDnkBX37Z7IvjU9wmS@YXvx3OUf3SdvV9QHySLXJ4uzHZaS39/AQ "C (gcc) ‚Äì Try It Online")
Keeps on printing random integers in \$[0,99]\$ until \$0\$ is printed.
[Answer]
# [Python 3](https://docs.python.org/3/), ~~66~~ 56 bytes
```
from random import*
x=1
while x:x=randint(0,99);print(x)
```
[Try it online!](https://tio.run/##K6gsycjPM/7/P60oP1ehKDEvBUhl5hbkF5VocVXYGnKVZ2TmpCpUWFXYgiQz80o0DHQsLTWtC4pA7ArN//8B "Python 3 ‚Äì Try It Online")
Thank you to [xnor](https://codegolf.stackexchange.com/users/20260/xnor), [danis](https://codegolf.stackexchange.com/users/99104/danis) and [mhawke](https://codegolf.stackexchange.com/users/61175/mhawke) for showing new stuff and helping improve the code!
[Answer]
# [Ohm v2](https://github.com/nickbclifford/Ohm), 10 bytes
```
‚Å∏‚Äπ#¬£D¬ßD,X‚ÄΩ
```
[Try it online!](https://tio.run/##y8/INfr//1HjjkcNO5UPLXY5tNxFJ@JRw97//wE "Ohm v2 ‚Äì Try It Online")
**Commented:**
```
‚Å∏‚Äπ#          push a list containing the integers in the range [0-99]
   ¬£    X‚ÄΩ   while the the picked number is not 0
    D        duplicate the list and
     ¬ßD,     pick a random number from the list and display it
```
[Answer]
# [C (gcc)](https://gcc.gnu.org/), 40 bytes
```
f(r){printf("%3d",r=rand()%100)*r&&f();}
```
[Try it online!](https://tio.run/##HYrLDkAwEADv/YqGkF1BKo4e/yKt0oQlq07i2@sxp8lkdDFpHWJHejnNKNvDG7eVcx8sMF47O/IWoqQ2Uc4dD2QAk0opzDhNLWBzh/eQ6@AIUFxCvnxZ/MajP5mkasQdHg "C (gcc) ‚Äì Try It Online")
[Answer]
# [Perl 5](https://www.perl.org/), ~~26 23~~ 21 bytes
*@KjetilS's comment inspired me to save even more bytes than suggested, and @DomHastings got another 2 bytes off by changing to `$=`*
```
say$==rand 100while$=
```
[Try it online!](https://tio.run/##K0gtyjH9/784sVLF1rYoMS9FwdDAoDwjMydVxfb//3/5BSWZ@XnF/3V9TfUMDA0A "Perl 5 ‚Äì Try It Online")
[Answer]
# [Lua](https://www.lua.org/), 43 bytes
```
repeat a=math.random(0,99)print(a)until a<1
```
[Try it online!](https://tio.run/##yylN/P@/KLUgNbFEIdE2N7EkQ68oMS8lP1fDQMfSUrOgKDOvRCNRszSvJDNHIdHG8P9/AA "Lua ‚Äì Try It Online")
]