Initial revision
[cacao.git] / tests / fp.java
1 public class fp {
2         public static void main(String [] s) {
3
4                 float a=10,b=10;
5                 int i;
6                 
7                 for (i=0; i<1000; i++) {
8                         a*=b;
9                         p(a);
10                         }
11                 
12                 for (a=0; a<1; a+=0.2) {
13                         for (b=0; b<1; b+=0.2) {
14                                 System.out.println ("-----------");
15                                 p(a);
16                                 p(b);
17                                 p(a+b);
18                                 p(a-b);
19                                 p(a*b);
20                                 p(a/b);
21                                 }
22                         }
23                 }
24                 
25                 
26         public static void p(double d) {
27                 System.out.println (d);
28                 }
29         public static void p(float d) {
30                 System.out.println (d);
31                 }
32
33         }