Skip to content

Instantly share code, notes, and snippets.

@kiwiyou
Last active January 14, 2022 13:36
Show Gist options
  • Save kiwiyou/ffb8beab11cbc64cb696639fd0c984c7 to your computer and use it in GitHub Desktop.
Save kiwiyou/ffb8beab11cbc64cb696639fd0c984c7 to your computer and use it in GitHub Desktop.
Baekjoon Online Judge Status Offender
// ==UserScript==
// @name Baeggro - BOJ Result Offender
// @match https://www.acmicpc.net/status*
// @grant none
// @version 4.0
// @author kiwiyou <[email protected]>, RanolP <[email protected]>
// @downloadURL https://gist.githubusercontent.com/kiwiyou/ffb8beab11cbc64cb696639fd0c984c7/raw/baeggro.js
// @updateURL https://gist.githubusercontent.com/kiwiyou/ffb8beab11cbc64cb696639fd0c984c7/raw/baeggro.js
// ==/UserScript==
const status = document.getElementById('status-table').rows;
let prev_id = '', streak = 0;
for (let i = status.length - 1; i > 0; --i) {
const id = status[i].cells[2].textContent;
const result = status[i].cells[3].firstChild;
if (id !== prev_id) {
prev_id = id;
streak = 0;
}
if (!result.matches('.result-ac')) {
result.textContent += 'ㅋ'.repeat(streak++);
} else {
streak = 0;
}
}
@kiwiyou
Copy link
Author

kiwiyou commented May 20, 2020

TamperMonkey (Chrome), GreaseMonkey / ViolentMonkey (Firefox)를 통해서 스크립트를 추가할 수 있습니다.

@Kinetic27
Copy link

잘 보고갑니다!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment