Skip to content

Instantly share code, notes, and snippets.

@l0w3
l0w3 / key_calc.py
Created January 16, 2024 22:44
key length calculator for polialphabetic ciphers
alfabeto = "ABCDEFGHIJKLMNÑOPQRSTUVWXYZ"
message = "GUVQA EQORN GVCOG PVGUG IWTQF GSWGG NRTKO GTCNW OPQSWGFGUE KHTGG UVGOG PUCLG ANQRW DNKSW GGPGN HQTQF GNCCUKIPCV WTCVG PFTCO CURWP VQUGP UWPQV C"
message = message.replace(" ", "")
def count_occurrences(message, letter):
res = 0
for i in message:
if i == letter:
res += 1
return (res)
@l0w3
l0w3 / ft_append.c
Last active November 16, 2022 09:42
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
int ft_strlen(char *str)
{
int i;
i = 0;
while (*str != '\0')
print(model.evaluate(X_test, y_test, verbose = 2))
for i in range(0, 10):
X_train, X_test, y_train, y_test = train_test_split(X, Y, test_size = 0.2)
model.fit(X_train, y_train, batch_size = 5, epochs = 5)
"""
Created on Wed Mar 18 17:55:11 2020
@author: alexr
"""
import tensorflow as tf
from tensorflow.keras.models import Sequential
from tensorflow.keras.layers import Activation, Dense, Flatten, MaxPool2D, Conv2D, Dropout
from sklearn.model_selection import train_test_split
"""
Created on Tue Mar 17 21:28:15 2020
@author: alexr
"""
import matplotlib.pyplot as plt
import os
import cv2
import random
#Creditos: parulnith https://gist.github.com/parulnith
#Importamos todas las librerias necesarias
import librosa
import librosa.display
import matplotlib.pyplot as plt
import os
import pathlib
cmap = plt.get_cmap('inferno')