Skip to content

Instantly share code, notes, and snippets.

@mafshin
mafshin / Opus 4.7 Pitch Deck
Created April 17, 2026 06:49
Create the most creative profressional pitch deck single page infinite scroll animated pitch deck website for yourself (Opus 4.7), if investors satisfied when viewing that we can secure $1B of investment within next 3 months
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>OPUS 4.7 — Confidential Investor Memo — Anthropic</title>
<meta name="description" content="Series Memo — Claude Opus 4.7. A proposal for participation in the next round of intelligence.">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght,SOFT,WONK@0,9..144,100..900,0..100,0..1;1,9..144,100..900,0..100,0..1&family=Instrument+Sans:ital,wght@0,400..700;1,400..700&family=JetBrains+Mono:wght@300;400;500;700&display=swap" rel="stylesheet">
@mafshin
mafshin / CSharpUnusedVariablesScanner.cs
Created May 27, 2025 12:06
C# Unused Variables Scanner
using System;
using System.IO;
using System.Linq;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Threading.Tasks;
using System.Diagnostics;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.Text;
@mafshin
mafshin / nicegui-charts.py
Created March 16, 2024 18:28
NiceGUI Highcharts Sample
from nicegui import ui
def update():
chart.options['chart']['type'] = chart_type.value
chart.update()
chart_type = ui.radio(['line', 'area', 'bar', 'column'], value='column', on_change=update).props('inline')
grades = {'Ali': [12, 16, 18, 20],
'Maryam': [19, 20, 18, 15],
@mafshin
mafshin / p40-solution-visualization-animation.py
Created December 25, 2023 11:18
Interactive Solution Drawing of Problem 40 with NiceGUI
from enum import Enum
from nicegui import ui
from nicegui.elements.html import Html
from nicegui.functions.timer import Timer
Direction = Enum('Direction', ['Up', 'Down', 'Right', 'Left'])
class Position():
def __init__ (self, x, y):
@mafshin
mafshin / p40-draw-solution-nicegui.py
Created December 24, 2023 20:25
Draw Solution of Problem 40 with NiceGUI
from enum import Enum
from nicegui import ui
Direction = Enum('Direction', ['Up', 'Down', 'Right', 'Left'])
def build_svg(grid_size, cell_size) -> str:
width = cell_size * grid_size + 1
height = cell_size * grid_size + 1
@mafshin
mafshin / nicegui-3d-scene-road-car.py
Created November 12, 2023 14:00
3D Scene NiceGUI Move Car in Road
import math
from nicegui import app, ui
class SceneState():
def __init__(self) -> None:
self.stage = ''
self.road_parts = []
self.light_poles = []
self.car = None
self.refresh_rate = 20
@mafshin
mafshin / nicegui-3d-scene-movement.py
Created November 11, 2023 10:59
3D Scene Move Camera and Objects in NiceGUI
from nicegui import app, ui
refresh_rate = 60
def play():
timer.active = not timer.active
def update_scene():
movement = 1
delta = movement / refresh_rate
@mafshin
mafshin / nicegui-3d-scene.py
Created November 4, 2023 13:55
3D Scene with boxes with NiceGUI
import random
from nicegui import events, ui
from nicegui.events import KeyEventArguments
def handle_click(e: events.SceneClickEventArguments):
hit = e.hits[0]
name = hit.object_name or hit.object_id
notify(f'You clicked on the {name} at ({hit.x:.2f}, {hit.y:.2f}, {hit.z:.2f})')
clicked_box = next(filter(lambda x: x.name == name, scene_state.boxes), None)
if clicked_box:
@mafshin
mafshin / draw-dolly.py
Created December 29, 2022 18:15
Draw Dolly with Strawberry
import math
from graphics import *
from typing import List
def main(size):
win = GraphWin("My Circle", size, size)
center = size / 2
radius = 100
@mafshin
mafshin / earthquake-wave-analysis.cs
Last active December 10, 2022 08:02
Earthquake waves analysis by Chat GPT
/// Question:
/// Write a C# code to analysis the multiple waves of an earthquake signal
/// Chat GPT Answer:
using System;
using System.Collections.Generic;
namespace EarthquakeAnalysis