Skip to content

Instantly share code, notes, and snippets.

View kijamve's full-sized avatar

Kijam López kijamve

View GitHub Profile
#include<cstdio>
#include<cstring>
#include<queue>
#define C(x) ( x > 'Z' ? x-'a' : x-'A' )
typedef unsigned int uint32; //Ahorramos escribir mucho texto asi LoL!...
typedef std::vector<char> t_way; //Ahorramos escribir mucho texto asi LoL!...
#include<cstdio>
#include<cstring>
// Aqui explicamos este algoritmo: https://www.youtube.com/watch?v=MpwbRV6lzR0
// Aprende a usar Grafos en C/C++ 😎 FACILITO 😁 y con Matriz de Adyacencia
// Con esta macro transformamos un caracter ASCII A-Z a un entero de 0-25.
// Sin importar que este en mayusculas o minusculas.
// IMPORTANTE: Este algoritmo no soporta acentos ni la letra ñ!...
#define C(x) ( x > 'Z' ? x-'a' : x-'A' )
#include <stdio.h>
#include <stdlib.h>
// Se utiliza stdlib.h para las funciones malloc y free
int main() {
int *edades, *edad; // Apuntadores sedeclaran con * antes del nombre de variable
int N, i;
printf("Cuantas edades vas a ingresar?:\n");
scanf("%d", &N);
edades = malloc(sizeof(int)*N);
/*
#!/bin/bash
find . -name '*.jpg' -or -name '*.png' |
while read f; do
ls -l "$f"
ff=$(identify -format "%m" "$f")
if [ $ff = "PNG" ]
then
#optipng "$f"
pngquant -f --speed 1 "$f" --output "$f"