answersLogoWhite

0

Exception handlers take care of asynchronous events (e.g. software arithmetic errors, hardware malfunction, normal termination of a different thread) other than interruptsthat require special handling in the software and would be inconvenient or impossible to check for using the standard conditional tests.

In general these asynchronous events make further processing impossible without this special handling, which may or may not correct any problems (if correctable) and then retry.

User Avatar

Wiki User

9y ago

What else can I help you with?

Continue Learning about Engineering

How do you repair an unhandled exception?

You can stop an unhandled exception by handling it. When your program crashes it will tell you exactly where it crashed and what exception it ran into. Dealing with the exception is the hard part. Generally, you want to take one of two approaches. The first is to make sure that the exception cannot happen. You may, for example, have to validate data to make sure that your users aren't allowed to give input which would result in a division-by-zero exception. The second is to allow the exception to be thrown, but use a try-catch block to catch it and print out a useful message instead of crashing. The method you choose will depend on what your program is supposed to do, who is using it, what exceptions are being thrown, where they're being thrown, etc. There's no silver bullet solution for handling an exception.


What data types allows unlimited character input?

String data type allows unlimited character intput


What is the input output fault finding technique?

Its fairly self explanatory, put the input IN then check the output at the OUTPUT.


Write a C program that takes a binary file as input and finds error check using different mechanisms?

write a c program that takes a binary file as input and finds error check using different mechanisms.


What is input in algorithm?

In an algorithm, input refers to the data or information that is provided to the algorithm for processing. It serves as the starting point for the algorithm's operations and can vary in type, such as numbers, text, or other data structures. The algorithm manipulates this input to produce an output, which is the result of its computations or actions. Properly defining and handling inputs is crucial for the algorithm's accuracy and effectiveness.

Related Questions

Write the 3 user defined exception in java?

1. Arithmetic Exception 2. Input Output Exception 3. Number Format Exception


What is the use of giving triggering as an input?

Event handling


What is the iPERMS definition of the word Exception?

An exception is a change in the normal flow of batches due to an issue that CANNOT be resolved by other input roles


What is a hardware device that allows users to enter data?

The primary example of a hardware component that allows user data input is a keyboard.


How do you repair an unhandled exception?

You can stop an unhandled exception by handling it. When your program crashes it will tell you exactly where it crashed and what exception it ran into. Dealing with the exception is the hard part. Generally, you want to take one of two approaches. The first is to make sure that the exception cannot happen. You may, for example, have to validate data to make sure that your users aren't allowed to give input which would result in a division-by-zero exception. The second is to allow the exception to be thrown, but use a try-catch block to catch it and print out a useful message instead of crashing. The method you choose will depend on what your program is supposed to do, who is using it, what exceptions are being thrown, where they're being thrown, etc. There's no silver bullet solution for handling an exception.


What file pointers are available to support file handling in c plus plus?

For file handling, use the input/output file stream objects, ifstream and ofstream, declared in the <fstream> header of the C++ standard library. Do not use C-style pointers unless you absolutely have to. The problem with "raw" resource pointers is that the resources are not automatically released when the pointers fall from scope. This has implications for exception handling strategies and exceptions are anything but exceptional, particularly where file handling is concerned. When an exception is thrown, every resource consumed between the exception handler and the exception itself must be released. The exception handler is ideally placed in a calling function that is best able to deal with the exception, thus the handler may not have access to the resources that were consumed up to the point the exception occurred. This means that every callee that consumes a resource must include its own localised exception handler which simply releases the resource and re-throws the exception. With resource handles (also known as smart pointers) we do not have this problem because resources are automatically released when the handle falls from scope. Thus our exception handling strategy becomes much more localised and our code becomes that much easier to maintain. And we get all this at no additional cost. Pointers may well give programmers a high-degree of control over resources, but that control has a cost in terms of maintainability and, in some cases, may actually result in reduced performance due to increased code size. Pointers certainly have their uses in C++, but resource management is not one of them. Always use resource handles unless you have good reason not to. In short, C-style resource pointers should only be used in C code, never in C++ code.


Which device allows you to input sound to the computer?

A Microphone


Is modem an input device?

I believe it is both an input and an output device, but I will check


What data types allows unlimited character input?

String data type allows unlimited character intput


What allows ou to enter or edit data in the worksheet?

input device


What is IME on your computer?

An input method is an operating system component or program that allows users to enter characters and symbols not found on their input device. For instance, on the computer, this allows the user of 'Western' keyboards to input Chinese, Japanese, Korean and Indic characters. Most operating systems use the term input method. It is commonly called input method editor(IME) in the Microsoft Windows operating systems.


Four major functions of an operating system?

Managing programs Managing Memory Handling input and output User Interface