Autor Beitrag
norman2306
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 222
Erhaltene Danke: 16

Win XP, Win 7 64-Bit
C# 4.0 (VS2010)
BeitragVerfasst: Di 27.07.10 15:36 
Servus!

Nun brauch ich auch mal Hilfe. Ich muss eine Studienarbeit bewerten. Da steht eine Grammatik drin. Ich möchte lediglich wissen, ob diese Grammatik interpretierbar ist (ich selber habe kein Informatik studiert. Ich weiß zwar grob, was eine Grammatik ist, aber die Symantik verstehe ich nicht).



ausblenden volle Höhe Quelltext
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:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
TicketContainer

Grammatik:

N = { S, T, U , V, X, Y_a, Y_m, Y_q, Y_p}

T = { p, a, q, m}

S = { S }

P = { 

S
 ->
 Y_p T
 
T
 ->
 Y_p T
 
T
 ->
 XT
 
T
 ->
 XU
 
T
 ->
 XV
 
T
 ->
 Y_a Y_m
 
U
 ->
 Y_m T
 
U
 ->
 Y_m U
 
U
 ->
 Y_m V
 
U
 ->
 m
 
V
 ->
 Y_q U
 
V
 ->
 Y_q T
 
X
 ->
 Y_a Y_m
 
Y_a
 ->
 a
 
Y_m
 ->
 m
 
Y_q
 ->
 q
 
Y_p
 ->
 p
 

}

a = AcTicket
m = Message
q = QuTicket
p = TicketContainer
Th69
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Moderator
Beiträge: 4807
Erhaltene Danke: 1061

Win10
C#, C++ (VS 2017/19/22)
BeitragVerfasst: Di 27.07.10 15:54 
Sagt dir der Begriff BNF bzw. EBNF etwas: de.wikipedia.org/wiki/Backus-Naur-Form bzw. de.wikipedia.org/wiki/EBNF ?

N scheint für Nichtterminal-Symbole zu stehen, T entsprechend für Terminalsymbol und S ist dann das Start-Terminal. Und P ist dann die Liste der sogenannten Produktionen (bzw. Produktionsregeln), also der Terminaldefinitionen.

Was genau meinst du aber jetzt mit "ob diese Grammatik interpretierbar ist"?