Challenge : Password Validator | Sololearn: Learn to code for FREE!

+35

Challenge : Password Validator

input a string (password: Domces223) and then check if the pass is valid or not. pass has to have: 1.Longer from 6 to 20 characters 2.atleast one uppercase letter (A-Z) 3.a number (1-9) 4.atleast one lowercase letter (a-z) if it is valid, print True. else print False. i think this will be harder i could give the hardest one, but it will ruin the fun good luck... you'll need it

8/8/2017 11:31:44 AM

Domces Games

29 Answers

New Answer

+25

My very simple 1-liner checker ( 1 line input 1 line checker ) :) https://code.sololearn.com/c24v1mWpf436/?ref=app

+16

I hate RegExp therefore i am not sure it works as it should, but why not... ? https://code.sololearn.com/WUqwstFItuu3/?ref=app

+13

well done guys... i dont know which is the best because you all did well so i wont put a check mark, but say that you all did well on this... i have more challenges to give, if you want, just put an upvote on this awnser new challenge is up

+9

Here's my attempt at it in Python. You also can't use whitespaces, as you can't in most passwords. https://code.sololearn.com/cVfIgU7DQUee/?ref=app

+8

I had never used regular expressions, I learned a bit about that. Thanks! https://code.sololearn.com/c9UTUU6OlhR6/?ref=app

+6

heres mine in c# https://code.sololearn.com/clPzkr6hrxIu/?ref=app

+5

https://code.sololearn.com/cxn70ZshCFDo Not hard with Character class methods in Java :D.

+5

I was working on another challenge for password strength when I came upon this one so I had to try ^^ https://code.sololearn.com/WMDqhj424lKI/?ref=app And here's the one for pwd strength if you'd like to check out https://code.sololearn.com/WCpuZRSQYDeS/?ref=app

+4

A simple (cramped, almost one-line) regex-y response in Ruby https://code.sololearn.com/cNmy4hteNpjF/?ref=app

+4

Check out mine. :) https://code.sololearn.com/c2hcjZdq1YaB/?ref=app

+4

Hope you like my code! https://code.sololearn.com/WHWEx6xkDpV2/?ref=app

+4

Here's my solution: https://code.sololearn.com/WCOV3vlFYax5/?ref=app

+4

simples password validator https://code.sololearn.com/Whv92nCkHDt4/?ref=app

+4

my code https://code.sololearn.com/c8Ded4RGW1Zu/?ref=app

+4

Password validation with code of mistake https://code.sololearn.com/cFvg7a2Egt3D If the return is 15, then the password has passed the check. The number from 0 to 14 means an error. For example: Code of mistake 10 (binary 1010) indicates an error in "uppercase" and "number"

+3

I'm not even sure if it works but: https://code.sololearn.com/cCdXBO7rx1J3/?ref=app please I need feedback

+3

Validation... Check Also My code.. https://code.sololearn.com/W6V4mYQV40Y5/?ref=app

+3

https://code.sololearn.com/ce6OYtm505B0/?ref=app

+2

Not really efficient using regex, since i had to use postive look ahead multiple times but it gets the job done. https://code.sololearn.com/cbSSPEuRWJ7j/?ref=app

+2

I made mine print out what is wrong with the password. It could be shorter ^^ https://code.sololearn.com/cLiI8q5chE4X/#py