Skip to content

Instantly share code, notes, and snippets.

View NathanAdhitya's full-sized avatar

Nathan Adhitya NathanAdhitya

View GitHub Profile
@NathanAdhitya
NathanAdhitya / google-meet-participants-xpath.js
Created April 22, 2024 02:04
Google Meet Participants xPath
$x('//div[@aria-label="Participants"][1]/div/div/div[2]/div[1]/span[1]').map(v => v.innerText)
@NathanAdhitya
NathanAdhitya / Excel FOREACH
Last active October 6, 2023 12:29
A simple Excel FOREACH formula function to iterate over an array. Add this code to Name Manager with the name FOREACH.
# Lines starting with # are comments, they are not code.
# Paste this into Name Manager. Give the name "FOREACH"
=LAMBDA(
arr; func; offset;
IF(
offset < COUNTA(arr);
VSTACK(
func(INDEX(arr; offset));
FOREACH(arr; func; offset+1)

Rangkuman TIK

Nathan, 24/02/2021

Teori Dasar

HTML adalah singkatan dari Hypertext Markup Language.
HTML dirancang pada konsep bahasa markup SGML, yang merupakan standar untuk membuat dokumen menggunakan tanda (markup) seperti paragraf, list, heading, dan lain-lain. (dalam HTML, markup yang digunakan adalah seperti p, li, h1)

Di dalam dokumen HTML, terdapat tag atau tanda. Tag adalah penanda awalan dan akhiran dari sebuah elemen. Tag dibuat menggunakan kurung siku <...>, dengan pasangan penutup menggunakan garis miring (/) di depan nama tag.
Untuk diingat: Tidak semua tag memiliki pasangan. Secara umum, mayoritas tag memilki pasangan penutup.

@NathanAdhitya
NathanAdhitya / awman.sk
Created June 14, 2021 14:48
A simple skript to prank your friends. Plays a creeper sound behind someone when command is executed.
command /awman <player>:
permission: donator.creeper
cooldown: 1 minute
trigger:
set {_rand} to a random integer between 1 and 3
if {_rand} is 1:
play sound "ENTITY_CREEPER_HURT" at location behind arg-1 for arg-1
else:
play sound "ENTITY_CREEPER_PRIMED" with pitch 0.5 at location behind arg-1 for arg-1
@NathanAdhitya
NathanAdhitya / classroom-discord.gs
Last active July 18, 2020 14:20
a google classroom to discord webhook. WARNING: not the most efficient method (look: push notifs [can't afford that]). this takes (amount of classes * 2)+1 requests / run.
/**
* @file Enhances student laziness by automatically posting classroom announcements and assignments through a Discord Webhook.
* @author Nathan Adhitya <me@natha.my.id>
*/
/*
KNOWN THINGS THIS THING WON'T ACCOUNT FOR:
- Google servers cutting the amount of data returned is not accounted for.
- Updates to existing announcement/course works
- Support for class material?
@NathanAdhitya
NathanAdhitya / minecraft.service
Created July 1, 2019 06:29
Minecraft systemd service
[Unit]
Description=Minecraft server
After=local-fs.target network.target
[Service]
WorkingDirectory=/home/minecraft/
User=minecraft
Group=minecraft
Type=forking
Restart=on-failure
--- This script allows the player to fly, as if they were in creative mode. Be warned, this isn't perfect, and lag may
--- result in your death.
--- Firstly we want to ensure that we have a neural interface and wrap it.
local modules = peripheral.find("neuralInterface")
if not modules then
error("Must have a neural interface", 0)
end
--- - We require a sensor and introspection module in order to gather information about the player