特牛生活网

Java(初学者)编写一个类Book具有name,price,press,author 并实现按照price大小排序, 然后遍历ArrayList输出每个Book对象,使用toString 方法打印_编写一个类book,具有name(书名)price(价格)press(出版社)author(作者)-CSDN博客

网友收藏
  • 链接地址:https://blog.csdn.net/m0_50729192/article/details/115448336
  • 链接标题:Java(初学者)编写一个类Book具有name,price,press,author 并实现按照price大小排序, 然后遍历ArrayList输出每个Book对象,使用toString 方法打印_编写一个类book,具有name(书名)price(价格)press(出版社)author(作者)-CSDN博客
  • 所属网站:blog.csdn.net
  • 被收藏次数:4357
文章浏览阅读1.8k次,点赞2次,收藏16次。编写一个类Book,具有name,price,press,author 然后创建5个对象放入ArrayList中,并实现按照price大小排序,然后遍历ArrayList输出每个Book对象, 使用toString 方法打印。import java.util.ArrayList;import java.util.Collections;import java.util.HashSet;import java.util.Iterator;import java.util.List;import _编写一个类book,具有name(书名)price(价格)press(出版社)author(作者)

上一篇:403 Forbidden!

下一篇:PSVMSA-CSDN博客