Skip to content

Instantly share code, notes, and snippets.

View mmpataki's full-sized avatar
🔒
locked in

Madhusoodan Pataki mmpataki

🔒
locked in
View GitHub Profile
@mmpataki
mmpataki / Configuration.java
Last active November 29, 2025 05:54
Cli arg parser
import java.io.FileReader;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.reflect.Field;
import java.util.*;
import java.util.stream.Collectors;
public class Configuration {
@Retention(RetentionPolicy.RUNTIME)
@mmpataki
mmpataki / index.html
Created August 5, 2025 18:23
render_N_Diff
<html lang="en">
<body>
<div id="output"></div>
<script>
let o1 = { a: 1, b: 2, c: { d: 3, e: 4 }, f: [5, 6] };
let o2 = { a: 1, b: 3, c: { d: 3, e: 5 }, f: [5, 7], g: "haha" };
let o3 = { a: 1, c: { d: 3, e: 5 }, f: [5, 7] };
render_N_Diff([o1, o2, o3], ['Object 1', 'Object 2', 'Object 3'], document.getElementById('output'));
</script>
@mmpataki
mmpataki / movable_item.js
Created August 5, 2025 19:59
movable ladybug
function MoveableItem(img, initX, initY) {
/* non class functions */
function now() { return +(new Date()) }
function move(img, x, y) {
img.style.left = `${x}px`
img.style.bottom = `${y}px`
}