Skip to content

Instantly share code, notes, and snippets.

View Bruno02468's full-sized avatar
☢️

Bruno Borges Paschoalinoto Bruno02468

☢️
View GitHub Profile
@Bruno02468
Bruno02468 / testa_todos.c
Last active November 4, 2018 22:39
[EP3] Testar todas as permutações de n panquecas!
/* pra ajudar meus bacanos da comp ~ borges */
#include <stdio.h>
#include <stdlib.h>
/* VOCÊ NÃO PODE IMPORTAR ESSE TRECO NO OFICIAL! */
#include <string.h>
/* INSIRA SUAS FUNÇÕES AQUI! PREENCHA A FUNÇÃO ordena()! */
int ordena(int *panquecas, int num_panquecas) {
@Bruno02468
Bruno02468 / ep2_sem_tempo_irmao.py
Last active June 2, 2022 02:41
EP2 da turma Python 2019 de MAC2166 -- só que em duas linhas (foi um desafio kkkkj)
z,k,m=(int(input("0 ou 1?\n")),int(input("chave?\n")),list(map(lambda c:"_ABCDEFGHIJKLMNOPQRSTUVWXYZ.".index(c),list(input("mensagem?\n").upper()))))
print("".join(map(lambda u:"_ABCDEFGHIJKLMNOPQRSTUVWXYZ."[u[1]], sorted([([i,k*i%len(m)][z]%28,[m[k*i%len(m)]-i,m[i]+i][z]%28) for i in range(len(m))], key=lambda u:u[0]))))
@Bruno02468
Bruno02468 / keybase.md
Created February 23, 2020 21:06
keybase.md

Keybase proof

I hereby claim:

  • I am bruno02468 on github.
  • I am bruno02468 (https://keybase.io/bruno02468) on keybase.
  • I have a public key ASCzOV-gwMogoe0Vk80-1TJ4EH8etCtpnZ-StC5QjUnjLwo

To claim this, I am signing this object:

@Bruno02468
Bruno02468 / pires.c
Last active October 6, 2022 09:58
"Como ler um arquivo palavra a palavra em C?" - disse o pires
/* pires.c
*
* boa pires na moral, jogou o fino
*
* programa que lê arquivo .txt palavra a palavra
*
* ==> domínio público <==
*/
#include <stdlib.h>
@Bruno02468
Bruno02468 / genome2img.py
Last active June 18, 2020 23:41
genome to image
#!/usr/bin/env python3
# written by bruno02468 in 2020-06-18
# quick 'n dirty script to turn genomes into square images, pads with 0
# it's a mess 'cause it was written in an hour or so
# no rights reserved
# ref: https://twitter.com/cib0rges/status/1273634584220049409
try:
from PIL import Image
except:
@Bruno02468
Bruno02468 / Compiling MYSTRAN with CMake.md
Last active November 12, 2021 01:10
Compiling MYSTRAN with CMake

Compiling MYSTRAN with CMake

Markdown base document revision: 1 (2021-02-01).
Author: Bruno Borges Paschoalinoto <bruno@paschoalinoto.com>

Setting up a build environment

In order to compile MYSTRAN using CMake, you first have to set up a proper building environment (i.e. toolchain and required programs/libraries).

You can skip this part if you've done it already (or if you really know what you're doing).

@Bruno02468
Bruno02468 / meusgrupo.md
Last active May 12, 2021 13:58
meusgrupo.md

meusgrupo.md

PCS 3734 - Lab. Redes

  • eu
  • hugo

PCS 3746 - Sistemas Operacionais

  • eu
@Bruno02468
Bruno02468 / gcc-arm-windows-vbox.md
Last active May 11, 2021 06:11
gcc-arm-windows-vbox.md

Como usar o gcc-arm no Windows pelo VirtualBox

Bruno Borges Paschoalinoto - nenhum direito reservado

1. Baixe e instale o VirtualBox

Baixe o VirtualBox no site oficial. No seu caso, você vai querer baixar o instalador Windows hosts - x86_64 (também conhecido como x64 ou amd64). Geralmente vai estar escrito só Windows hosts mesmo.

Não mude nenhuma opção no instalador.

@Bruno02468
Bruno02468 / fix_images.py
Created May 9, 2021 07:42
script for batch fixing image dimensions
#!/usr/bin/env python3
# fix_images.py
# author: bruno borges paschoalinoto
# no rights reserved
# written for my friend @LucasGiannella
import sys, os, math
from itertools import repeat
try:
@Bruno02468
Bruno02468 / sumario.py
Created May 11, 2021 21:46
gerador de sumário pro lucas janela
#!/usr/bin/env python3
# sumario.py
# autor: bruno borges paschoalinoto
# nenhum direito reservado
# escrito para o esplêndido pipi de @LucasGiannella
import sys, os, re
class Picture(object):
def __init__(self, obj, inst, loc, when, bg, rep):