source: liacs/coco/tests/optimize/commonsubexpr.p0@ 81

Last change on this file since 81 was 2, checked in by Rick van der Zwet, 15 years ago

Initial import of data of old repository ('data') worth keeping (e.g. tracking
means of URL access statistics)

File size: 245 bytes
RevLine 
[2]1program commonsubexpr;
2
3var a : integer;
4
5function calc(a,b,c: integer; d,e,f: real): real;
6
7begin
8 calc := ((a+b+c)*(a+b+c)+((a*d)+(a*d)*(e * f))+(a+b+c))/((a*d)+(a+b+c))
9end;
10
11begin
12 a := readinteger;
13 writereal(calc(a,2,3,1.0,2.0,3.0))
14end.
Note: See TracBrowser for help on using the repository browser.