Skip to content

Instantly share code, notes, and snippets.

View guwidoe's full-sized avatar

Guido Witt-Dörring guwidoe

  • EFS Consulting
  • Vienna
  • 12:28 (UTC +02:00)
View GitHub Profile
@eugeneyan
eugeneyan / mandelbrot-mojo.md
Last active April 4, 2024 15:52
Benchmarking Mojo vs. Python on Mandelbrot sets

Mandelbrot in Mojo with Python plots

Not only Mojo is great for writing high-performance code, but it also allows us to leverage huge Python ecosystem of libraries and tools. With seamless Python interoperability, Mojo can use Python for what it's good at, especially GUIs, without sacrificing performance in critical code. Let's take the classic Mandelbrot set algorithm and implement it in Mojo.

We'll introduce a Complex type and use it in our implementation.

Mandelbrot in python

@guwidoe
guwidoe / VBA-AccurateTimer.bas.vb
Last active March 30, 2024 22:45
Cross-platform accurate timer for VBA code
' Cross-platform VBA implementation of a high-precision timer.
' (Works on Windows and on macOS)
'
' Author: Guido Witt-Dörring
' Created: 2023/04/03
' Updated: 2023/05/16
' License: MIT
'
' ————————————————————————————————————————————————————————————————
' https://gist.github.com/guwidoe/5c74c64d79c0e1cd1be458b0632b279a
@guwidoe
guwidoe / GetLocalOneDrivePath.bas.vb
Last active July 18, 2024 06:38
VBA Function to get the local path of a OneDrive/SharePoint synchronized Microsoft Office file
'Attribute VB_Name = "GetLocalOneDrivePath"
'
' Cross-platform VBA Function to get the local path of OneDrive/SharePoint
' synchronized Microsoft Office files (Works on Windows and on macOS)
'
' Author: Guido Witt-Dörring
' Created: 2022/07/01
' Updated: 2024/07/08
' License: MIT
'
@t-mat
t-mat / KnownFolderIdExample.cpp
Created February 11, 2020 12:06
[WIN32] Shell API KNOWNFOLDERID example
/*
WIN32 Shell API KNOWNFOLDERID example
Wait. What has happned to CSIDL?
It's retired. CSIDL has the following note:
https://docs.microsoft.com/en-us/windows/win32/shell/csidl
> As of Windows Vista, these values have been replaced by KNOWNFOLDERID values.
//
// Regular Expression for URL validation
//
// Author: Diego Perini
// Created: 2010/12/05
// Updated: 2018/09/12
// License: MIT
//
// Copyright (c) 2010-2018 Diego Perini (http://www.iport.it)
//