Last change
on this file was 2, checked in by bird, 22 years ago |
Initial revision
|
-
Property cvs2svn:cvs-rev
set to
1.1
-
Property svn:eol-style
set to
native
-
Property svn:executable
set to
*
|
File size:
578 bytes
|
Line | |
---|
1 | public class PR160
|
---|
2 | {
|
---|
3 | static final int len = 100;
|
---|
4 |
|
---|
5 | public static void main(String args[])
|
---|
6 | {
|
---|
7 |
|
---|
8 | double[] a = new double[len];
|
---|
9 | double[] b = new double[len];
|
---|
10 |
|
---|
11 | for (int i = 0; i < len ; i++)
|
---|
12 | {
|
---|
13 | a[i] = 0.65;
|
---|
14 | }
|
---|
15 |
|
---|
16 | System.arraycopy(a, 0, b, 0, len);
|
---|
17 |
|
---|
18 | boolean errors = false;
|
---|
19 |
|
---|
20 | for (int i = 0; i < len ; i++)
|
---|
21 | {
|
---|
22 | if (a[i] != b[i])
|
---|
23 | {
|
---|
24 | System.out.println("ERROR! " + a[i] + " != "
|
---|
25 | + b[i] + " at index " + i);
|
---|
26 | errors = true;
|
---|
27 | }
|
---|
28 | }
|
---|
29 |
|
---|
30 | if (!errors)
|
---|
31 | System.out.println("ok");
|
---|
32 |
|
---|
33 | }
|
---|
34 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.