Skip to content

Commit

Permalink
Update java-quiz.md (Ebazhanov#1012)
Browse files Browse the repository at this point in the history
  • Loading branch information
saurabhvaish93 authored Jan 21, 2021
1 parent 501b585 commit f0ceb2f
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions java/java-quiz.md
Original file line number Diff line number Diff line change
Expand Up @@ -332,8 +332,8 @@ System.out.println(n);

- [ ] new SimpleDateFormat("yyyy-MM-dd").format(new Date())
- [ ] new Date(System.currentTimeMillis())
- [ ] LocalDate.now()
- [X] Calender.getInstance().getTime()
- [X] LocalDate.now() <--------- LocalDate is newest class added in java 8
- [] Calender.getInstance().getTime()

#### Q23. Fill in the blank to create a piece of code that will tell wether int0 is divisible by 5:

Expand Down Expand Up @@ -627,16 +627,16 @@ public class Main {
System.out.println(object);
}
```
- [ ]
- [X]
```
Iterator it = theList.iterator();
for (it.hasNext()) {
for (it.hasNext()) { <---------- compiler error
System.out.println(it.next());
}
```
- [X]
- [ }
```
theList.forEach(System.out::println);
theList.forEach(System.out::println);
```

#### Q42. What method signature will work with this code?
Expand Down

0 comments on commit f0ceb2f

Please sign in to comment.