Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

/ * The program implements a dice rolz with random value between 1 and 6. * The rolled value is stored in a variable called

image text in transcribed
/ * The program implements a dice rolz with random value between 1 and 6. * The rolled value is stored in a variable called "diceRoll" * Use that variable to implement the following logic * if the diceRoll is 1 or 2 : print "Low value" * if the diceRolz is 3 or 4: print "Hedium value" * if the diceRoll is 5 or 6 : print "High value" / public static void main(String[] args) f int min=1 int max=6; int range =maxmin+1 int diceRoll = (int) (Math. randon() range) +1; II Write your logic below

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions