SME
Engineering Programming (MATLAB/Python) · Problem type
Syntax, runtime or logic error
Use this for “Is math.sin(30), meant as 30°, a syntax, runtime or logic error?”
Sort
When does the bug show itself?
Tap a card, then tap its group.
A syntax error stops the program before it runs, a runtime error stops it partway, and a logic error runs to the end with a wrong answer.
Assumptions
•
The snippets are Python; MATLAB sorts the same bugs into the same three kinds.
•
math.sin and MATLAB’s sin take radians; sind takes degrees.
Topic check
See what you know: 5 questions on this topic
New questions each time. Pass to mark it complete.