88.0k views
2 votes
Which of the following assignment statements contains a LOGICAL error? I multiply two numbers when they need to be added I write an instruction that is ambiguous I write an instruction the computer does not understand The errors in (a), (b) and (c) are all syntax errors, none of them are logical errors

User Merdan
by
4.9k points

1 Answer

1 vote

Answer:

(a) I multiply two numbers when they need to be added

Step-by-step explanation:

By definition, a Logical Error is a coding mistake resulting in the program NOT producing the expected result or behaviour, however the source code is syntactically correct and the program could compile and execute unaware of the error, or result on a crash during runtime.

User Sudhir Dhumal
by
5.5k points