This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#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!... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#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' ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#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); | |
/* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/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" |