一道java考试试题求解

匿名网友 |浏览827次
收藏|2020/01/01 13:07

满意回答

2020/01/01 13:29

完整的参考/******start******/class Waiter implements Bell { public Waiter(int n) { System.out.printf("Waiter %d receives a bell ring.\n",n); } public void answer() { System.out.printf("the customer is served."); }}class Customer { Bell bell; public Customer(Bell b) { bell=b; } public void served() { bell.answer(); }}/******end******/

whoami1978

其他回答(0)
0人关注该问题
+1

 加载中...