Conversation
main.py
Outdated
| # making sure the input is an integer | ||
| while True: | ||
| num = int(input("How many name example you want me to create for you?\n")) | ||
| if num is not int: |
There was a problem hiding this comment.
Please can you recheck the 'if' statement? I think it's 'if num is int'
main.py
Outdated
| if len(name) >= 2 and isinstance(name, str): | ||
| break | ||
| else: | ||
| print("don't be a fool a give me a real name!") |
There was a problem hiding this comment.
It would be great if you could recheck the minor grammatical errors and punctuations!! Just a suggestion for this outstanding code.
|
Excellent thinking and a totally different approach worth experimenting!! |
|
|
||
| If you ask me, my favourite is John Chirpy | ||
| ``` | ||
| Currently the script generate all surnames in Italian, this can be changed modifying the last two letters of the `url variable` to `en` for English |
There was a problem hiding this comment.
Hey Luca, I like the detail you put in your README. Nice work!
| @@ -0,0 +1,67 @@ | |||
| """ | |||
There was a problem hiding this comment.
Good use of the docstring at the start of the file, I really like how you integrated the API call into the script.
| # generated_names list | ||
| madeup_name = f"\n{name.title()} {nickname.title()}" | ||
| print(madeup_name) | ||
| generated_names.append(madeup_name) |
There was a problem hiding this comment.
Good use of comments in the script! It's clear to me what you're implementing.
| # and check is an acceptabe input | ||
| while True: | ||
| name = str(input("Please provide a first name of your choice:\n")) | ||
| if len(name) >= 2 and re.match("^[a-zA-Z]+$", name): |
There was a problem hiding this comment.
Nice use of regular expressions!
No description provided.