0
Need help for solving problem in c#.
Write a console c# program that Get the two different 3 digits integers (num1=123, num2=543) from user and check whether their corresponding place same total and if same should print True else False. Eg. 1. 1+5=2+4=3+3 // print True Eg. 2. 3+4=5+1=6+2 // print False Thank you
7 Answers
+ 1
do you need more help on this... if so post your code... with the issue you are having... :)
0
if they are in the same position in each number, can you separate them out by number... add those numbers then compare?
0
Thank you for quick reply! yes it should compare
0
Ok I will when I get in my laptop. right now iâm in working so i posted via mobile app
thank you
0
Thanks for your hard work @Jozef!
This is exactly what I need to be work is done. But let's go little-advanced.
1) Users need to correctly enter 3 digits number otherwise exiting the program or do the loop until users correctly input the numbers
eg. if users input is 15424 print the msg, not 3 digits number/something else
2) Use the separate method.
0
I have done with little different then yours code but I don't know its right way or not, because I'm new in C#. Here is a link for a code https://code.sololearn.com/csybtcxRpwax. I had try with adding same through an array. Unfortunately, I couldn't later I found one solution that I implemented. I'd like to go through the both if you could help me that would be greatly appreciated!