Skip to content

Instantly share code, notes, and snippets.

View mauro-balades's full-sized avatar
😪
Focusing

mauro 🤙 mauro-balades

😪
Focusing
View GitHub Profile
#unified-extensions-view {
--uei-icon-size: 16px;
.unified-extensions-item {
margin-block: 0 !important;
border-radius: var(--arrowpanel-menuitem-border-radius) !important;
> .unified-extensions-item-action-button {
.unified-extensions-item-message-deck {
display: none;
@mauro-balades
mauro-balades / plfm.md
Created February 18, 2024 21:17
The perfect programming language (for me)

Welcome

The quest for the perfect programming language is a personal and subjective journey, as the most suitable language can vary widely depending on an individual's needs, preferences, and the context of the task at hand. No single programming language can claim to be universally perfect, but there is often one that aligns closely with a specific developer's requirements, providing the right balance of power, expressiveness, and ease of use.

Here's what I would love to have in a perfect programming language:

  • Static typing
  • Compiled and low-level (I need speed)
  • High-level constructs (combined with point #2)
  • Exception-based Error Handling
@mauro-balades
mauro-balades / nice.py
Last active September 5, 2023 13:25
Nice python turtle shape
import turtle as sneaky_turtle
sneaky_turtle.speed(0)
i = 120/2
while True:
for i in range(6):
sneaky_turtle.forward(100)
sneaky_turtle.left(360/6)
sneaky_turtle.left(i/2)
i *= 2
@mauro-balades
mauro-balades / a.c
Last active June 11, 2023 10:47
beauty-of-c
#include __FILE__
pleaseKillMe;
@mauro-balades
mauro-balades / format.sh
Last active March 6, 2023 16:23
Format your C++ projects
# note (1): remember to change the ".cpp" to the extension (and the path) you want formatted
# note (2): this works with header files too
find src/**/*.cpp | xargs clang-format -i -style="{IndentWidth: 4,TabWidth: 4}"
@mauro-balades
mauro-balades / main.c
Last active February 26, 2023 11:19
Represent a number with value "1"
#include <stdio.h>
int main() {
int num=++*(*(unsigned int(*)[1])(unsigned int[]){0}+!(*(unsigned char*)(&((unsigned int*)0)[1])))<<((!(sizeof(int)%2))?16:0);
printf("num is now %d",num);
return 0;
}
@mauro-balades
mauro-balades / __main__.py
Last active May 14, 2023 07:05
Create infinite accounts with logbug
from selenium import webdriver
import undetected_chromedriver as uc
import random
import string
import csv
from time import sleep
def id_generator(size=50, chars=string.ascii_uppercase + string.digits):
return ''.join(random.choice(chars) for _ in range(size))
@mauro-balades
mauro-balades / index.md
Last active January 17, 2023 11:18
Why machinarium is great

Introduction

Machinarium is a point ‘n’ click adventure game that obligate players to use logic in order to proceed with the story. It takes around 3-4 hours (that's what it took me to complet it) and those 3 hours where filled with amazing discoveries. The game allows the player to discover more about the main character (commonly known as "Josef" by the community) and how he got in he's current situation.

Josef does not want to conquer the world, he just wants to reclaim his original state and have a good life with his girlfriend. For him to achieve him his goals, he must help other first and the ones he helped would return the favour. Machinarium is a good example of games that wants to transmit a message to it's player base and also about how a game can use some techniques to make it feel more inmersive and atrackt the user into wanting to discover more about the story.

Machinarium was published on 2009 along with other games such as call of duty. This made it difficult for it to expand on it's

@RobertAKARobin
RobertAKARobin / safari.md
Last active January 5, 2024 05:41
Safari's date-picker is the cause of 1/3 of our customer support issues

Safari's date-picker is the cause of 1/3 of our customer support issues

...and obviously we're building a workaround. But I'm absolutely flabbergasted that a standard <input type="date"> HTML field, in a standard browser, from a company that bases its reputation good design, could be so dreadful.

The context

I'm the developer for a startup that sells a genetic test to recommend medications for high blood pressure. For medical reasons we need to know our customers' birth date. Most of our customers are in their 60s or older. We've found that many of them use iPads or iPhones. And they're the ones who complain to our customer support that our site is unusable.

The problem

@mauro-balades
mauro-balades / SCSS.md
Created April 20, 2022 15:17 — forked from jareware/SCSS.md
Advanced SCSS, or, 16 cool things you may not have known your stylesheets could do

⇐ back to the gist-blog at jrw.fi

Advanced SCSS

Or, 16 cool things you may not have known your stylesheets could do. I'd rather have kept it to a nice round number like 10, but they just kept coming. Sorry.

I've been using SCSS/SASS for most of my styling work since 2009, and I'm a huge fan of Compass (by the great @chriseppstein). It really helped many of us through the darkest cross-browser crap. Even though browsers are increasingly playing nice with CSS, another problem has become very topical: managing the complexity in stylesheets as our in-browser apps get larger and larger. SCSS is an indispensable tool for dealing with this.

This isn't an introduction to the language by a long shot; many things probably won't make sense unless you have some SCSS under your belt already. That said, if you're not yet comfy with the basics, check out the aweso