Skip to content

Instantly share code, notes, and snippets.

View peruribalasurya-debug's full-sized avatar

Bala Surya Peuri peruribalasurya-debug

  • USA
View GitHub Profile
function computePolkadotScore(asciiArt) {
const lines = asciiArt.split('\n');
// ----------- 1. Find lips x-range -----------
// Lips are ~~~~~~ on the line containing "~~~~~~' ' `"
// Stripping ' ` - from "~~~~~~' ' `" leaves ~~~~~~
// lipsStartX = first ~, lipsEndX = last ~ of that group
let lipsStartX = -1;
let lipsEndX = -1;