174k views
2 votes
What kind of c++ error is divided by zero?

User RoastBeast
by
6.0k points

1 Answer

5 votes

Answer:

mathematical error or math error

Step-by-step explanation:

In c++ The " mathematical error or math error " is found when dividing any number by zero The exception handling is used to solved this problem if we not used exception handling then the output of divided by zero is printed infinity .

we use try catch block in exception handling .

Exception are the run time error .Try block contain the code where the exception can occur and catch block defined which kind of error is that .

try

{

// contains the code where exception is occured

}

catch( )

{

// contains code or described which kind of error

}

User Jacob Wang
by
6.1k points