A few years ago, I started a Facebook page and shared a fantasy story draft in separate “note” posts.
That story was the first time I put myself out there and wrote something that I shared with the public. I was, understandably, terrified.
Yet, there was one thing that kept me going. It was a reader from Thailand that read and commented on those posts.
She was so excited by the story, and even though I didn’t have anyone else commenting or reading (as far as I knew), I kept going because I knew she would see that story continue…
When I started writing online, I was in a very dark place. I used to check my bank account every day, decline invitations from friends, and mostly just hoping this dark period of my life would go away.
When things don’t work, many so-called gurus of Content Creation use the cliche advice of “remember why you started” as potential motivation to help new creators push forward. And for someone like me, the ask essentially means remembering one of the terrifying periods of my life.
No, thank you.
In this article, I want to explore why that doesn’t work and how…
The way we write Python classes is very straightforward. Here’s an example:
That is the core definition of a class.
Any class in python which uses non-static methods needs an init function. This is how you write one:
Every time you create a new object from this class, that method will run, and the generated object will have all the methods and members defined in the class. Here’s a complete example:
self.x = 12my_obj = MyClass()
# print(my_obj.x) will print 12.
A class can define methods that…
In the last 24 hours, this video showed up on the Dropout video library detailing the news:
Dropout produced the video for D20 fans, but Brennan suggested that other shows return to the studio, too. That means shows like Game Changer and Um, Actually, among others.
The current D20 season will end in two and a half weeks as only three episodes are left. Based on past seasons, that means that the newest season has already been filmed and is now in post-production.
It’s so exciting to go back to the dome and other sets, even though Dropout did amazingly…
In 2011, I started writing articles for a website called EzineArticles. It was like today’s HubSpot, where people would write many marketing and sales articles and press releases.
Even though this website was the first I ever wrote for in English, I still chose to show up as the expert. I didn’t have a clue what I was doing, but at the time, I was following this program that promised to make me rich.
It was as if affiliate marketing and pyramid schemes had a love child. But I was inexperienced and didn’t recognize this was a fluke. …
Author’s Note: when I say You — You know who you are. Obviously not 100% of the world population is antisemitic.
Over the past week, I’ve been called a Nazi, a dead man, children killer, murderer, stupid, pathetic, hypocrite, and many other slurs that are best not spoken.
All for supporting the fact that the country I live in has the right to self-determine and defend itself.
The fact that I leave my home in Tel Aviv and fearing that someone won’t try to stab me as often happens in Jerusalem, the capital of my country, means that this conflict…
In many higher programming languages like C++, C#, Python, and Java, inheritance is a useful tool to ensure you don’t repeat code in multiple places.
In this piece, I’ll teach you how to use Python’s inheritance feature. I will not dive into the advantages or disadvantages of using inheritance over a different kind of programming theory — like composition. Nevertheless, I highly recommend you go read about it.
Let’s dive in!
Let’s say you have a server handler class (don’t worry if you don’t know what that means, treat it as just a class), and part of its behavior is…
Python 3 provides a built-in function that you can use to open files:
This way is the easy, naive one to read a text file:
my_file_handler = open("readme.txt", "r")
my_file = my_file_handler.read()
I’ll give you a better way to do so, but for now, let’s go over some definitions.
open() the path to a file, and based on how you want to process the file, choose the mode to operate. There are a few basic options here:
During my first week in the Israeli Defense Forces — over fifteen years ago — a bomb dropped in the base I served in, less than three hundred feet from where I was standing on open ground.
I was temporarily deafened and a little bit in shock, but I survived. Any time there are rockets fired at Israel, my mind takes me back to that one moment. People around me are screaming. Recruits abandon all training and running ahead to find a safe place from the ricochets. People are crying and losing control — both mentally and physically.