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:
432 bytes
|
Line | |
---|
1 | interface I
|
---|
2 | {
|
---|
3 | int i = 1, ii = PR162.out ("ii", 2);
|
---|
4 | }
|
---|
5 |
|
---|
6 | interface J extends I
|
---|
7 | {
|
---|
8 | int j = PR162.out ("j", 3), jj = PR162.out ("jj", 4);
|
---|
9 | }
|
---|
10 |
|
---|
11 | interface K extends J
|
---|
12 | {
|
---|
13 | int k = PR162.out ("k", 5);
|
---|
14 | }
|
---|
15 |
|
---|
16 | public class PR162
|
---|
17 | {
|
---|
18 | public static void main (String[] args)
|
---|
19 | {
|
---|
20 | System.out.println (J.i);
|
---|
21 | System.out.println (K.j);
|
---|
22 | }
|
---|
23 |
|
---|
24 | public static int out (String s, int i)
|
---|
25 | {
|
---|
26 | System.out.println (s + "=" + i);
|
---|
27 | return i;
|
---|
28 | }
|
---|
29 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.