15
2
According to legend, almost everyone is outgolfed by Dennis. If not, they will be.
Now I'm curious if I'm one of those 'almost everyone'.
You will be given a link to an answer in the format of https://codegolf.stackexchange.com/questions/[QUESTION ID]/[QUESTION NAME]/#[ANSWER ID]
.
Find the length of the code, which we will assume as the last number on the first line (markdown wise) of the answer in the link.
Then, search for Dennis' answers, and do the same.
Now compare the input's and Dennis' answers code length, and if it is out-golfed (meaning one or more answer of Dennis' is shorter than that of the input answer), output a truthy value, and if not, a falsy value.
If there is no answer belonging to Dennis on the same question as the answer, output a falsy value.
Examples
Rules
- You may use any form of truthy/falsy value.
- The question of the answer you're given will always be code-golf.
The question may not have an answer of Dennis', but the inputted answer will never belong to Dennis.
You may assume there is always a number on the first line of the answer.
3Can we assume there will always be an answer by Dennis on the given question, and that the given answer will not be Dennis' answer? – Skidsdev – 2017-05-10T10:42:08.413
@Mayube No, and yes. – Matthew Roh – 2017-05-10T10:42:34.940
Do we need to handle paging or can we assume both answers will be on the same page if there are multiple pages of answers? – Shaggy – 2017-05-10T10:42:45.510
@Shaggy former. – Matthew Roh – 2017-05-10T10:43:06.450
@SIGSEGV If there is no answer by Dennis do we output false because Dennis has not outgolfed the answer? – Skidsdev – 2017-05-10T10:43:43.693
@Mayube Yes.... – Matthew Roh – 2017-05-10T10:44:27.500