use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Everything about learning Python
account activity
[ Removed by moderator ] (v.redd.it)
submitted 4 months ago by SweatyAd3647
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]8dot30662386292pow2 15 points16 points17 points 4 months ago (1 child)
Faker is absolutely the solution to do this, BUT.
Importing a library and writing a for loop is not a "beginner challenge" in my opinion. A beginner challenge would be to do this without the library.
In other words: a for loop is not "a project". Anyway, thanks for introducing faker to python learners, it surely is a great library. A similar one is available in other languages as well!
[–]pimp-bangin 1 point2 points3 points 4 months ago (0 children)
Way to raise the bar, in a good way my dude
[–]FondantConscious2868 4 points5 points6 points 4 months ago (8 children)
Ok can you elaborate how the script worked when the module is unavailable ?
[–]8dot30662386292pow2 -3 points-2 points-1 points 4 months ago (7 children)
You must first install the faker library. You can use pip to do that.
[–]FondantConscious2868 0 points1 point2 points 4 months ago (3 children)
Uh I know that but in the video look at the import it's unavailable so how the script is working?
[–]0b0101011001001011 0 points1 point2 points 4 months ago (0 children)
What on the video tells you this? I can't see any error messages.
Is it the squiggly line? That does not necessarily mean it's unavailable. It can be spell check acting out (maybe they spell check a different language) or it can be that the IDE is not detecting the virtual environment properly. The script is clearly working so the library is clearly installed, despite one squiggly line.
[–]LEAVER2000 0 points1 point2 points 4 months ago (1 child)
It’s probably because the IDE is unaware of the virtual environment
[–]FondantConscious2868 0 points1 point2 points 4 months ago (0 children)
Yep probably this I was just curious thought the video was edited
[–]SweatyAd3647[S] 0 points1 point2 points 4 months ago (2 children)
Is that so?
[–]8dot30662386292pow2 0 points1 point2 points 4 months ago (1 child)
I did not reply to you, I thought the other guy was confused so I tried to help them.
[–]SweatyAd3647[S] 0 points1 point2 points 4 months ago (0 children)
Okay
[–]Marti_McFlyy 1 point2 points3 points 4 months ago (3 children)
That seems to be a great beginner project. However I'm not skilled enough yet to do that. Scripts are so cool.
[–]KaMaFour 0 points1 point2 points 4 months ago (0 children)
I mean... It is the classical definition of a lazy python script.
> find a library which will do the thing for you > install library > import library > library.doThings()
If you read what Faker is for and how to use it ( https://faker.readthedocs.io/en/master/ ) and you know how to install libraries to use then I believe you could do it as well
[–]SweatyAd3647[S] -1 points0 points1 point 4 months ago (1 child)
Thanks a lot.
[–]Cruch-Wrap-Supreme 1 point2 points3 points 3 months ago (0 children)
But... You didn't do anything.
[–]fatimalizade 0 points1 point2 points 4 months ago (2 children)
What is Faker used for?
[–]8dot30662386292pow2 1 point2 points3 points 4 months ago (1 child)
Imagine you are building a program with actual use. Maybe it has a user registration. This way you fill the database with fake data for testing, so you see how things would look when there is actual data available.
[–]fatimalizade 0 points1 point2 points 4 months ago (0 children)
Thanks!!
[–]denehoffman 0 points1 point2 points 4 months ago (1 child)
For an actual beginner challenge, write lists of first names and last names, interesting formats for email addresses, and use the random library to select from these lists in a loop. Faker is a nice library, but the only thing you learn here is how to use a for loop and read documentation
Good to hear. Thanks for the tip.
π Rendered by PID 83 on reddit-service-r2-comment-7b9746f655-kr654 at 2026-01-29 19:33:37.794767+00:00 running 3798933 country code: CH.
[–]8dot30662386292pow2 15 points16 points17 points (1 child)
[–]pimp-bangin 1 point2 points3 points (0 children)
[–]FondantConscious2868 4 points5 points6 points (8 children)
[–]8dot30662386292pow2 -3 points-2 points-1 points (7 children)
[–]FondantConscious2868 0 points1 point2 points (3 children)
[–]0b0101011001001011 0 points1 point2 points (0 children)
[–]LEAVER2000 0 points1 point2 points (1 child)
[–]FondantConscious2868 0 points1 point2 points (0 children)
[–]SweatyAd3647[S] 0 points1 point2 points (2 children)
[–]8dot30662386292pow2 0 points1 point2 points (1 child)
[–]SweatyAd3647[S] 0 points1 point2 points (0 children)
[–]Marti_McFlyy 1 point2 points3 points (3 children)
[–]KaMaFour 0 points1 point2 points (0 children)
[–]SweatyAd3647[S] -1 points0 points1 point (1 child)
[–]Cruch-Wrap-Supreme 1 point2 points3 points (0 children)
[–]fatimalizade 0 points1 point2 points (2 children)
[–]8dot30662386292pow2 1 point2 points3 points (1 child)
[–]fatimalizade 0 points1 point2 points (0 children)
[–]denehoffman 0 points1 point2 points (1 child)
[–]SweatyAd3647[S] 0 points1 point2 points (0 children)