Anonymous
Anonymous asked in Computers & InternetComputer Networking · 4 weeks ago

I am new to computer coding c#, and need help? ?

My example assignment copied and paste below.

Write a console application to ask for two numbers and display the result only if the symbol input and the word input match as follows:ExampleEnter x: 4Enter y: 2Enter either a symbol or a word (+, -, *, /, add, sub, mul, div): +To confirm, if you entered a symbol, this time enter its matching word (or vice versa): add4 + 2 = 6ExampleEnter x: 4Enter y: 2Enter either a symbol or a word (+, -, *, /, add, sub, mul, div): addTo confirm, if you entered a symbol, this time enter its matching word (or vice versa): +4 + 2 = 6ExampleEnter x: 4Enter y: 2Enter either a symbol or a word (+, -, *, /, add, sub, mul, div): +To confirm, if you entered a symbol, this time enter its matching word (or vice versa): subMismatched operations!Requirements1. All the values above are only examples.2. Use || and && in the program.3. If the two inputs are different (e.g. + and sub, div and -, or + and /, etc.), then do not display the result, but display an error message e.g. “Mismatched operations!”

There are no answers yet.
Be the first to answer this question.