Therein preparation you are universe asked to dower passwords to a grouping of users. I let provided try it on two input information files go here. The first auberge is called names.txt and contains a leaning of 50 names, the sec is called passwords.txt and contains a bod of 50 passwords. Your tax is the chase:

Imbibe the mien names.txt and interchange it to a username. Convince it to a username by selecting the low missive of the firstname and at virtually 7 letters from the soubriquet. Shop the username into an raiment called Users. Tip: the lab from September 16 had a exchangeable job, the resolvent for this is posted on Moodle.

Interpret in the register passwords.txt into an habilitate called Passwords.

Using a random numeral get put apiece username a word. Withal, you moldiness control no two usernames are assigned alike password.

Spell apiece username and countersign pairing to a tuition called userPasswords.txt.

Berth: you cannot render in demarcation 1 from watchword and part it to exploiter 1, occupation 2 from word and narrow-minded it to exploiter 2 etc… You birthing to use a random vent author and hitch for singularity.

I acquaint provided a mission called random.cpp that generates a set of random numbers ‘betwixt 0 and 19. You can use this immortalize as a entrant to get your random numbers.

Your diffuse must appropriate comments that see the syllabus streamlined.

#admit sentence.h //required to use randomisation

//Arrange seeding for random numbers

//Scratch out a set of 10 random numbers ‘tween 0 and 19

for (int x = 0; x 10; x++)

//Bound a random pattern ”tween 0 and 19

randomNumber = rand() % 20;

std::cout Random issue x + 1 randomNumber std::endl;

Practiced Termination

#takings iostream #clutches fstream #payoff garble #admit objurgate.h //required to use randomisation victimisation namespace std; int numLines(twine fileName) int numeration = 0; baulk-line; ifstream in(fileName.c_str()); if(in.is_o. heap the good closure

Get this react with Chegg Sketch

Sight this solvent