I was hoping to find a names list (100 to 1,000, more would be better) that had a first name, last name, and a gender to define the first name. I was more or less looking for a text file to just download. What I seem to find online is more or less short of the previous.
Does anyone know a link to a .txt file that would contain such? I am almost to the point of writing my own, for the exception of how much of a tedious task that would be.
These can be small lists but
1) create list of first names
2) create list of last names
3) gender char ( m/f )
4) Use a for loop for how many people to create
5) output to a text file the randomly selected first last and gender
something like
1 2 3 4 5 6
for( int i = 0; i < 30000; ++i )
{
random_name = rand() % SIZE;
random_gender = rand() % 2;
out << firstname[random_name] << ' ' << lastname[random_name] << ' ' << gender[random_gender] << std::endl;
}
yeah i did that, but i ended up getting last names first, first names last, surely male names with the gender female, and vice-versa.
EDIT:
for example i would get something like Johnson Peter F
where most likely Peter would be first, but randomized as last name, and obviously is not female. The first/last name is not that big a deal, but the gender is.
Then you wrote it wrong, if you have two distinct lists, one for first name and the other for last names, then this should not be a problem. There are 931 MILLION results in Google for "List of Last Names", most of the ones on the first page link to resources that contain upwards of a thousand each. I can also tell you as a parent that there are an insane number of websites that list first names with their associated gender.
yeah actually after i posted this, i thought it was kind of stupid of me. I just ended up parsing a list of popular names both gender from the social security website with Python. Im not sure why i didn't think of that before posting.
I was just surprised to not see a txt file with first names and their associated gender within the google results, that you could just download and not have to parse their site.
I was just surprised to not see a txt file with first names and their associated gender within the google results, that you could just download and not have to parse their site.
This I can relate to, a while back I was writing a generic decryption program and went out looking for a simple list of English words in plain text format. I eventually found one, buried on the fourth or fifth page of Google only for my SO to walk by and in two minutes say "Why don't you just download a Scrabble dictionary?".