0

Need to help with quiz

There are variables double a, double b with random values in Also is variable char ch with random sign (+,-,*,/) I need to write a code (calculator) which operates a and b and write result in variable double c

16th Apr 2020, 10:19 AM
Владислав Мещеринов
Владислав Мещеринов - avatar
5 Answers
+ 1
You can find in the Internet code for random number generation. Using several "if else" or one "switch" statement you can choose operator depending on random value.
17th Apr 2020, 11:33 AM
Stephan
Stephan - avatar
+ 1
There is the book in Russian. It's very helpful for beginners. https://vk.com/doc7608079_481057841?hash=1e02a1a293479f3d96&dl=299d99a3dcce23ff75
17th Apr 2020, 11:37 AM
Stephan
Stephan - avatar
0
What a help do you need? If you want to see solution it's bad idea. You learn when you solve problems by yourself. I recommend you to read this book before starting programming. It will help you to learn much faster. Here Is a link to the book https://drive.google.com/file/d/16EFtqewwJJ5-AWtt3vFtkPofl-Mg9n44/view?usp=drivesdk I'll send Russian version later
16th Apr 2020, 10:53 AM
Stephan
Stephan - avatar
0
I rather can't figure out which method i could use to do this. I don't want to see completed code I'm just wondering to get solution to solve it
17th Apr 2020, 10:20 AM
Владислав Мещеринов
Владислав Мещеринов - avatar
0
I'll try. Thanks a lot.
17th Apr 2020, 11:41 AM
Владислав Мещеринов
Владислав Мещеринов - avatar