Run ❯
Get your
own Java
server
❯
Run Code
Ctrl+Alt+R
Change Orientation
Ctrl+Alt+O
Change Theme
Ctrl+Alt+D
Change Language
Go to Spaces
Ctrl+Alt+P
import java.util.Random; public class Main { public static void main(String[] args) { Random rand = new Random(); int dice = rand.nextInt(6) + 1; System.out.println("Is the number between 1 and 6? " + (dice >= 1 && dice <= 6)); } }
Is the number between 1 and 6? true