+ 2

[Solved]

How do I make my code only output numbers "1-6" instead of "0-6" https://sololearn.com/compiler-playground/cygzcYirrYds/?ref=app

12th Apr 2024, 9:45 AM
Khalil
4 Answers
+ 6
your code is right just two mistakes 1) Add = after first_die and second_die 2) remove ; before '+minValue' Like this short first_die= (rand() % (max_value - min_value )) + min_value ;
12th Apr 2024, 11:22 AM
AzhagesanăƒŸ(✿)
AzhagesanăƒŸ(✿) - avatar
+ 2
It worked. I appreciate the help đŸ€
12th Apr 2024, 2:21 PM
Khalil
+ 2
Khalil , Some people add [Solved] to the title so people know help is no longer needed.
12th Apr 2024, 2:38 PM
Rain
Rain - avatar
+ 1
Thanks for letting me know
12th Apr 2024, 5:07 PM
Khalil