This file contains 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
from os import rename, path, listdir | |
try: | |
path_of_dir = input('Enter path of directory with your file:') | |
ext = input('Print file extension (unquoted) (".jpg" for example):') | |
list_of_filename = listdir(path_of_dir) | |
count = 1 | |
for file in list_of_filename: | |
full_old_name = path.join(path_of_dir, file) | |
new_name = "{:0>6}".format(count) + ext |
This file contains 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
from string import ascii_lowercase, ascii_uppercase | |
import random | |
chars = ascii_lowercase + ascii_uppercase + "0123456789!?@#$*" | |
n = int(input("Enter password length: ")) | |
m = int(input("Enter how many passwords to generate: ")) | |
def gen_char_password(n): | |
for i in range(n * m): |
This file contains 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 <ctype.h> | |
#include <cs50.h> | |
#include <stdio.h> | |
#include <string.h> | |
#include <stdlib.h> | |
//prototype | |
string valid_key(string key); | |
string do_text(string start_text, string key); | |
void swap(char *a, char *b); |