Reference no: EM13935008
The MiniCalc application was designed to perform basic math calculations: +, -, *, /. However, in its present form, this application
needs some improvements.
1. Test all operators with the values 8 and 2 to make sure it works as expected.
2. Test the program with 99999 + 99999. This should raise a 'System.OverflowException' exception.
3. Test the program with '9 divide 0'. The result shows 'infinity'. Actually, the calculation should raise an exception
'System.DivideByZeroException'. Modify the program so that the user input is validated before the divide operation is performed.
For a divide by zero, modify the program to raise an exception, then add the code to handle the exception.
4. Now test the '-' operator using the following test cases: (1) variable1 = 32000 and variable2 = -767 and (2) variable1 = 32000
and variable2 = -768. For the first test case, the result should be 32767. For the second test case, you should get an exception.
In a Word document, write 2 paragraphs explaining what is different from the first case and fix the problem to handle the
exception.
Attachment:- MiniCalc.zip
Include structured error handling on all forms.
: Create a patron letter-writing feature that includes a functional RichTextBox control.
|
Total quality management-approach to long-term success
: Total quality management (TQM) is a management approach to long-term success through customer satisfaction. The approach is dependent on all members of the organisation participating in improving processes, products, services, and the culture in w..
|
Why is important for organisms to have respiratory surfaces
: Why is it important for organisms to have respiratory surfaces? What challenges do terrestrial animals with respiratory surfaces face? Identify three types of respiratory surfaces/structures. Explains why each structure is necessary for the organi..
|
Ideas you learnt on interpretation
: Input: The input to the program shall be a text file containing binary encoding of some x86 code. Here is a sample input file ("sampleinput.txt"): 8d 4c 24 04 83 e4 f0 50 c1 f8 02 34 2e 89 e5 45 83 ec 04 80 7c 24 04 81 5d This is for the following..
|
Applications designed to perform basic math calculations
: Test all operators with the values 8 and 2 to make sure it works as expected.what is different from the first case and fix the problem to handle the exception.
|
How company past strategy affect it in the present
: A convenient way to investigate how a company's past strategy and structure affect it in the present is to chart the critical incidents in its history - that is, the events that were the most unusual or the most essential for its development into ..
|
How are cios different in regard from other chief officers
: Why do you think this is the case? How are CIOs different in this regard from other chief officers, for example, in finance, HR, or marketing?
|
Add a label control to the form
: add a Label control that shows the path to the file being processed.add a Label control that shows the path to the file being processed.
|
Wha primary difference between passive and active transport
: Imagine that you are a pediatrician and one of your patients is a newborn who may have a lysosomal storage disease. You remove some cells from the patient and examine them under the microscope. What would you expect to see? Design a series of test..
|