move JFlex to CE source
[fedora-idea.git] / tools / lexer / jflex-1.4 / examples / interpreter / example.as
blob81522472e175f4c908d26cbd8f01681767bdf656
2 // example program for interpreter testing
3 // contains division and modulo functins
5 input a,b
6 functions div(x,y) = if x < y
7 then 0
8 else div(x-y,y)+1
9 fi,
10 mod(x,y) = if x < y
11 then x
12 else mod(x-y,y)
14 output div(a,b), mod(a,b)
15 arguments 324, 17
16 end