Skip to content

Web Server Logs :Java Programming: Arrays, Lists, and Structured Data (Java Programming and Software Engineering Fundamentals Specialization) Answers 2025

Question 1

Least likely change to LogEntry class:
✔️ The toString method is modified to include a String parameter.
❌ All others are reasonable changes.

(ToString never takes parameters—so this is the least likely modification.)


Question 2

✔️ In readFile, the log entries were not stored in records.
❌ All other options

(The LogEntry is created but never added to the records ArrayList.)


Question 3

✔️ Option 1

for (LogEntry le : records) {
if (le.getStatusCode() > num) {
System.out.println(le);
}
}

All others ❌.


Question 4

✔️ 59 unique IPs


Question 5

✔️ 8 unique IP visits on Sep 27


Question 6

✔️ 11 IPs with status code 200–299


Question 7

✔️ 5 (most visits by a single IP)


Question 8

✔️ 188.162.84.63
❌ all other IP options


Question 9

✔️ Sep 30
❌ Sep 24
❌ Sep 26
❌ Sep 28


Question 10 — Two IPs returned

✔️ 103.57.41.178
✔️ 210.4.104.99
❌ all others


📌 SUMMARY TABLE

Q# Answer
1 toString with parameter
2 records not stored
3 Option 1 (correct loop)
4 59 unique IPs
5 8 unique visits
6 11 IPs
7 5 visits
8 188.162.84.63
9 Sep 30
10 103.57.41.178, 210.4.104.99