Division by zero
CodeChefOpen on judge ↗
Debug the following C++ code? #include using namespace std; double division(int a, int b) { return (a / b); } int main () { int x; int y; double z; int x=10; int y=0; z = division(x, y); cout Input: 10 0. Output: division by zero not possible..
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start