Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Python: IF THEN | IF THEN ELSE | ID COMP_OP INT ID ASSIGN INT t_COMP_OP= r'==|!=|>=|

Python:

IF THEN | IF THEN ELSE |

ID COMP_OP INT

ID ASSIGN INT

t_COMP_OP= r'==|!=|>=|<=|<|>'

t_ID= r'[a-z]+'

t_ASSIGN= r'='

Valid syntax?

(1) grade > 70

(2) GRADE = 100

(3) grade = 100

(4) if grade >= 70 then grade = 100

(5) if grade >= 70 then if grade < 80 then grade = 75 else grade = 100

Choices for 5 questions above are

(A) yes

(B) No, it contains a lexical error

(C) No, it contains syntax error

Please explain your pick. Thanks.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Concepts

Authors: David Kroenke, David Auer, Scott Vandenberg, Robert Yoder

9th Edition

0135188148, 978-0135188149, 9781642087611

More Books

Students also viewed these Databases questions

Question

Example. Evaluate 5n+7 lim 7-00 3n-5

Answered: 1 week ago

Question

How do modern Dashboards differ from earlier implementations?

Answered: 1 week ago