Password Challenge

Password Challenge

Help out a company with bad security practices to validate their passwords with Excel!



You are given the following requirements:

– At least six characters long

– No spaces

– At least one number

– At least one special character



Drop your solution in the comments below 🙂

Our solution:

=IF(AND(LEN(F4)>=6;NOT(ISNUMBER(SEARCH(” “;F4)));
COUNT(FIND({0;1;2;3;4;5;6;7;8;9};F4))>0;
COUNT(FIND($K$4:$K$16;F4))>0);”Valid”;”Invalid”)


3 thoughts on “Password Challenge

  1. Inte den snyggaste lösningen, men den funkar. MĂ„ste finnas ett bĂ€ttre sĂ€tt Ă€n mitt…..

    =AND(LEN(F4)>=6;ISERR(NOT(SEARCH(” “;F4)>0));
    OR(IFERROR(SEARCH(0;F4)>0;FALSE);
    IFERROR(SEARCH(1;F4)>0;FALSE);
    IFERROR(SEARCH(2;F4)>0;FALSE);
    IFERROR(SEARCH(3;F4)>0;FALSE);
    IFERROR(SEARCH(4;F4)>0;FALSE);
    IFERROR(SEARCH(5;F4)>0;FALSE);
    IFERROR(SEARCH(6;F4)>0;FALSE);
    IFERROR(SEARCH(7;F4)>0;FALSE);
    IFERROR(SEARCH(8;F4)>0;FALSE);
    IFERROR(SEARCH(9;F4)>0;FALSE));
    OR(IFERROR(FIND(“!”;F4)>0;FALSE);
    IFERROR(FIND(“@”;F4)>0;FALSE);
    IFERROR(FIND(“#”;F4)>0;FALSE);
    IFERROR(FIND(“$”;F4)>0;FALSE);
    IFERROR(FIND(“&”;F4)>0;FALSE)
    ;IFERROR(FIND(“/”;F4)>0;FALSE);
    IFERROR(FIND(“ÂŁ”;F4)>0;FALSE);
    IFERROR(FIND(“$”;F4)>0;FALSE);
    IFERROR(FIND(“(“;F4)>0;FALSE);
    IFERROR(FIND(“)”;F4)>0;FALSE);
    IFERROR(FIND(“{“;F4)>0;FALSE);
    IFERROR(FIND(“}”;F4)>0;FALSE);
    IFERROR(FIND(“%”;F4)>0;FALSE)))

  2. =IF(AND(LEN(F4)>=6;ISERROR(FIND(” “;F4));
    OR(INDEX(ISERROR(MID(F4;SEQUENCE(1;LEN(F4);1;1);1)+0)=FALSE;0));
    OR(INDEX(COUNTIF($K$4:$K$16;MID(F4;SEQUENCE(1;LEN(F4);1;1);1))
    >0;0)));”Valid”;”Invalid”)

Leave a Reply

You must be logged in to post a comment.

More blog posts

Tired of Googling?
Get the best Excel tips every week. Subscribe to our newsletter.

About the author

Emil har jobbat pÄ Learnesy som produktutvecklare i flera Är och ligger bakom flera av Learnesys kurser. Han har en utbildning inom datavetenskap med ett stort intresse för det analytiska och teoretiska. Utöver Finska och Svenska snackar Emil Àven flytande Excelfunktioner!