java:jfc_intf_collection
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
java:jfc_intf_collection [2021/05/22 03:38] – [1ος τρόπος - For-Each Loop] gthanos | java:jfc_intf_collection [Unknown date] (current) – external edit (Unknown date) 127.0.0.1 | ||
---|---|---|---|
Line 24: | Line 24: | ||
| | ||
public static void main(String args[]) { | public static void main(String args[]) { | ||
+ | Collection< | ||
students = new LinkedList< | students = new LinkedList< | ||
students.add(new Student(" | students.add(new Student(" | ||
Line 37: | Line 38: | ||
==== 2ος τρόπος - iterator ==== | ==== 2ος τρόπος - iterator ==== | ||
- | Μπορείτε να αντικαταστήσετε την '' | + | Μπορείτε να αντικαταστήσετε την '' |
<code java> | <code java> | ||
- | public void iterateList() { | + | public |
Iterator< | Iterator< | ||
while( it.hasNext() ) { | while( it.hasNext() ) { |
java/jfc_intf_collection.1621654713.txt.gz · Last modified: 2021/05/22 02:38 (external edit)