Parse and summarize HTTP access logs
You get log lines, each meant to hold an IP address, a timestamp, a URL or API path and a status code. Parse each line, decide whether it is valid, and report the total number of requests, how many returned 4xx and 5xx errors, and the failure percentage. Say how you treat malformed lines.
No answer yet. Write the first one; the best answer gets endorsed.
