Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
4003CEM-compilation/passwords.h
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
25 lines (21 sloc)
573 Bytes
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
#ifndef LIBRARY_H | |
#define LIBRARY_H | |
#include <math.h> | |
#include <string> | |
/** | |
* Calculate the number of possible passwords for the | |
* given character set and password length | |
* | |
* @param characters number of different possible characters in the password | |
* @param length password length | |
* @return number of possible passwords | |
*/ | |
int possible_combinations( int characters, int length ); | |
/** | |
* Returns if a given password is a good one | |
* | |
* @param password the password to test | |
* @return was it a good password | |
*/ | |
bool good_password( std::string password ); | |
#endif |