This commit is contained in:
2020-01-29 12:56:06 +01:00
commit 04efff0d15
51 changed files with 1673 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
/*Input from user and convert to lower case*/
const firstName = prompt("Hva er fornavnet ditt?").toLowerCase();
const surname = prompt("Hva er etternavnet ditt?").toLowerCase();
const domain = prompt("Skriv inn et domenenavn", "eksempel.no").toLowerCase();
/*Combine the input and print it out*/
const email = firstName + "." + surname + "@" + domain;
console.log("Email: " + email);
/*Combine and add a random number between 1 and 100 with a little bit lower probability for 1 and 100*/
const mailNum = parseInt((Math.random() *100) +1);
const altEmail = firstName + "." + surname + mailNum + "@" + domain;
console.log ("Alternativ Email: " + altEmail);