AuD
Lecture 'Algorithmen und Datenstrukturen' (code examples)
aud.example.expr.ExpressionTreeExample Class Reference

ExpressionTree: minimal example. More...

Static Public Member Functions

static void main (String[] args)
 

Detailed Description

ExpressionTree: minimal example.

Definition at line 3 of file ExpressionTreeExample.java.

Member Function Documentation

◆ main()

static void aud.example.expr.ExpressionTreeExample.main ( String[]  args)
static

Definition at line 5 of file ExpressionTreeExample.java.

5 {
6 ExpressionTree tree=new ExpressionTree
7 (new Times(),
8 new ExpressionTree
9 (new Plus(),
10 new ExpressionTree(new Number(2)),
11 new ExpressionTree(new Number(3))),
12 new ExpressionTree(new Number(5))
13 ); // (2+3)*5
14 System.out.println(tree);
15 System.out.println(tree.getValue());
16 }

References aud.example.expr.ExpressionTree.getValue().

+ Here is the call graph for this function:

The documentation for this class was generated from the following file: