Skip to content

Instantly share code, notes, and snippets.

View Panadestein's full-sized avatar
🔣
2‿3 ≡⟜(+´)´∘⋆˜⟜(+´⊸⋈) ↕n

Ramón L. Panadés-Barrueta Panadestein

🔣
2‿3 ≡⟜(+´)´∘⋆˜⟜(+´⊸⋈) ↕n
View GitHub Profile
@Panadestein
Panadestein / fizzgolf.py
Last active August 16, 2024 01:14
On the solution of the FizzBuzz challenge
"""Several Python FizzBuzz implementations ranging from very naive to very golf-like"""
# Naive `for` loop (+150 bytes)
for i in range(1, 101):
if not i % 15:
print('FizzBuzz')
elif not i % 3:
print('Fizz')
elif not i % 5:
print('Buzz')
@Panadestein
Panadestein / cheb_spiral.py
Last active June 15, 2020 22:32
Python Chebyshev Spiral
"""
Fancy Chebyshev Spiral plotter.
The original idea comes from [Wolfram MathWorld]
(https://mathworld.wolfram.com/ChebyshevPolynomialoftheFirstKind.html)
This is my Python implementation of the original
plot by Trott 1999, pp. 10 and 84.
"""
import numpy as np