# Julia, <s>17</s> 16 bytes

<!-- language-all: lang-julia -->

    f(n)=2>rand(1:n)

This is a function that generates a random integer between 1 and `n` and tests whether it's less than 2. There will be a 1/n chance of this happening, and thus a 1/n chance of returning `true`.

Saved 1 byte thanks to Thomas Kwa!