Day 006 - Project 6 : Make your own login program

If you have any questions, comments or issues with this project please post them here!

I was wondering if there was a js version of this you know of.

There is no JS course made by Replit as of now.

If you go to the Learn page on Replit and scroll down to the coding lessons, there is an Intro to JS tutorial. This is not made by Replit though (it was made by me :smiley:), nor is it 100 days or anywhere near as in depth as Replit’s 100 days of Python would be. I believe there are two other tutorials there related to JavaScript (one’s NodeJS).

2 Likes

What the elif did I build today? A hack proof login system! Try breaking in :space_invader:!!

https://replit.com/@JackAdem/Day-006-Project-6-Make-your-own-login-program?v=1

Day 6 of #Replit100DaysOfCode #100DaysOfCode.

1 Like

You can see the usernames and passwords in the source code so it’s not that secure. If you really want to keep them hidden, use secrets. Also some very questionable usernames and passwords you’ve used…

1 Like

If you really want to keep them hidden, use secrets can you tell me how?

You will learn about this later in the course!

1 Like

Oh… Whoops, my bad… Oh well.

Refer to this page for info on secrets.

I’m on Day6 of 100 Days of Code and had a question on -

username = input("Username > ")

For input variables- what’s the difference if I use “:” versus “>”?

In the previous days - for all input variables I used “:” but in this most recent lesson they switch it up to “>”.

How do I know when to use which one?

Thanks!

It doesn’t make a difference if it is ">" or ":" as it is part of the string they also both tell the user to enter there input.

1 Like

There is no difference. The string you put in input() is only a prompt to the user, it doesn’t change the value input()

username = input("Username: ")

And

username = input("Username > ")

are both exactly the same programmatically. The only difference is aesthetic.

1 Like

So, this not is a little late but I did do Day 6. It was just it was a little late and didn’t want to make notes about it. Thank you!

Replit- https://replit.com/@Chandler0Bing/100-Days-Of-Code-Day-6

1 Like

Question:


Hi, I am creating Employee Login programme for my #100daysofCode. As a beginner written a basic code for login. Would be really helpful if someone would help me with introducing advanced aspects to the code.

When the employee logs in he puts in usual things such as username and password. But after that I him to have him a customized message based on journey (using mode of transport say bicycle, weather and the diet designed). For example, it should pick weather from New York and give him the relevant message

Repl link:


https://replit.com/@jyoti10/day6100-days#main.py
code snippet

print("MY LOGIN SYSTEM")
print("++++++++++++++++")
username = input("Username > ")
password = input("Password > ")
department = input("task for the day > ")

if username == "David" and password =="fgh6868" and department == "sales":
    print("Hello David. Hope you enjoyed your bike ride in beautiful streets of Sydney")
    print("Create sales deck for xyz client. This gonna be another best one from you")
elif username == "Mark" and password == "gh25toa" and department == "data analytics":
    print("Hi Mark, it's going to be hot day in New York, don't forget to drink loads of water")
    print("please work on player accuracy data. We want our team to win!")   
elif username == "Paul" and password == "127asd" and department == "Foodzone":
    print("Hi Paul, yesterday you left the kitchen clean, Good Job!")
    print("Prepare food as per the food chart. You are an awesome chef!")
else:
    print("Errr....I don't know you. Bye!")

Can you format the code with the option in ask (either in the wheel or the one looking </> ?
This will help us reading your code

1 Like

@whileTRUEpass here is everything formatted correctly

2 Likes

Thanks @QwertyQwerty88
@jyoti10 what do you exactly want to know about the advanced aspects? I guess it is not of this code right?

1 Like

I want to know if we can add real time weather from google based on person’s location. I am at nascent stage of learning so wanted to know if its possible in this python code

Thanks @QwertyQwert54 for the help !

2 Likes

Thanks for the help!