>
shame_leaderboard
// the most roasted code on the internet
·
// the most roasted code on the internet
// the most roasted code on the internet
<?php
// Nome do arquivo original
$arquivoOriginal = 'foto.jpg';
// Nome do arquivo a ser criado (cópia)
$arquivoCopia = 'copias/foto_backup.jpg';
// A função copy() realiza a cópia
if (copy($arquivoOriginal, $arquivoCopia)) {
echo "Arquivo copiado com sucesso!";
} else {
echo "Erro ao copiar o arquivo.";
}
?>
function calculateTotal(items) {
var total = 0;
for (var i = 0; i < items.length; i++) {
total = total + items[i].price;
}
if (total > 100) {
console.log("discount applied");
total = total - 5;
}
// TODO: handle tax calculation
// TODO: handle currency conversion
return total;
} const highlight = useCallback(
(code: string, langKey: LanguageKey | null): string => {
if (!highlighter) return escapeHtml(code);
const shikiLang = langKey ? LANGUAGES[langKey]?.shiki : null;
const lang =
shikiLang && loadedLangsRef.current.has(shikiLang)
? shikiLang
: "plaintext";
try {
return highlighter.codeToHtml(code, {
lang,
theme: "vesper",
});
} catch {
return escapeHtml(code);
}
},
[highlighter],
);export const db = new Proxy({} as PostgresJsDatabase, {
get(_target, prop, receiver) {
if (!_db) _db = createDb();
return Reflect.get(_db, prop, receiver);
},
});import Link from "next/link";
function Navbar() {
return (
<nav className="flex h-14 w-full items-center justify-between border-b border-border-primary bg-bg-page px-10">
<Link href="/" className="flex items-center gap-2">
<span className="font-mono text-xl font-bold text-accent-green">
{">"}
</span>
<span className="font-mono text-lg font-medium text-text-primary">
devroast
</span>
</Link>
<div className="flex items-center gap-6">
<Link
href="/leaderboard"
className="font-mono text-[13px] text-text-secondary transition-colors hover:text-text-primary"
>
leaderboard
</Link>
</div>
</nav>
);
}
export { Navbar };
@import "tailwindcss";
@theme inline {
--color-warm-50: #faf9f7;
--color-warm-100: #f5f3f0;
--color-warm-200: #e8e4de;
--color-warm-300: #d4cec4;
--color-warm-400: #a39e93;
--color-warm-500: #7a756b;
--color-warm-600: #5c574f;
--color-warm-700: #45413b;
--color-warm-800: #2d2a26;
--color-warm-900: #1a1815;
--color-olive-50: #f4f6f0;
--color-olive-100: #e6eadd;
--color-olive-200: #cdd6bb;
--color-olive-300: #a8b88e;
--color-olive-400: #879a6a;
--color-olive-500: #6b7f4e;
--color-olive-600: #54653c;
--color-olive-700: #3f4d2d;
--color-olive-800: #2d3720;
--color-olive-900: #1c2315;
--color-navy-50: #f0f3f7;
--color-navy-100: #dce4ef;
--color-navy-200: #b4c5d9;
--color-navy-300: #8aa3be;
--color-navy-400: #6482a3;
--color-navy-500: #476889;
--color-navy-600: #345170;
--color-navy-700: #1e3a5f;
--color-navy-800: #152d4a;
--color-navy-900: #0e1f35;
--color-whatsapp: #25D366;
--color-whatsapp-dark: #1fba59;
--font-sans: var(--font-geist-sans);
}
* {
-webkit-tap-highlight-color: transparent;
}
body {
background: var(--color-warm-50);
color: var(--color-warm-900);
-webkit-font-smoothing: antialiased;
}
::selection {
background: var(--color-navy-200);
color: var(--color-navy-900);
}