-
Notifications
You must be signed in to change notification settings - Fork 0
/
5.2.b_while
31 lines (30 loc) · 2.38 KB
/
5.2.b_while
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
while ( i > 0 ) num = num + 1
//Не е еизречение от езика защото няма {} и ;?
while_statement
|
---------------------------------------------------------
WHILE LPAREN expression RPAREN block
| | | | |
while ( | ) LBRACKET statement RBRACKET
| | | |
| { | }
| simple_statement SEMICOLON
simple_expression relational_operator simple_expression | |
| | | assignment ;
term GREATER_THAN term |
| | variable BECOMES assignable
factor INT_LITERAL | | |
| | IDENTIFIER = expression
variable 0 | |
| num |
IDENTIFIER signed_term additive_operator signed_term
| | | |
i term PLUS term
| | |
factor + factor
| |
variable INT_LITERAL
| |
IDENTIFIER 1
|
num