i like programming :) https://ryanchou.dev | Top 2000 Writer on Medium | Author of A Beginner’s Handbook to Python

Today we will learn how to send desktop notifications with Python. For this we will just need a computer with Python installed.

You’ll need Plyer’s notification for this project:

# In CMD or terminalpip install plyer# In projectfrom plyer import notification

You can send notifications by calling the `notify()`

function from notification.

It takes four parameters:

`title`

The large header text at the top of a notification.

`message`

The longer, smaller text where you put more detailed information.

`app_icon`

The image that appears next to the title and message.

`timeout`

How long the message should show…

What is a two-pointers algorithm?

To put it simply, the two pointers technique is an efficient algorithm on a sorted list which can find a pair of elements in linear time.

Let’s learn about it while solving the famous problem (that we’ve solved before!), Two Sum!

The idea is that you can adjust the pointers in order to find the answer. For example, the steps to find 5 in this list below would be like this.

5

| |

[2, 3, 4, 9](Sum is larger: (9 + 2 > 5) so we move the right pointer.) |…

According to Brilliant, a greedy algorithm is:

“An algorithm that makes the optimal choice at each step as it attempts to find the overall optimal way to solve the entire problem.”

Now this might make it seem like a greedy algorithm is a complicated and intricate algorithm, but this actually isn’t the case!

Let’s take a look at an example problem, and we’ll see how it goes!

From **HackerRank**:

Alice is a kindergarten teacher. She wants to give some candies to the children in her class. All the children sit in a line and each of them has a rating…

The concept of FizzBuzz is **really** simple.

Write a program which prints every number from one to one hundred, but:

- If you encounter a number which is divisible by 3, print
**Fizz**. - If you encounter a number which is divisible by 5, print
**Buzz**. - If you encounter a number which is divisible by 3 and 5, print
**FizzBuzz**. - If you encounter a number which is divisible by neither 3 or 5, print
**the number**.

Given an integer **N**, print the **N**th number which isn’t Fizz, Buzz, or FizzBuzz.

Given:

8Output:

14Explanation:If we were to write out the first…

When you look something up on Google, you’ll get a flurry of related queries to your search. What are these, and how can we scrape them with Pytrends?

When you look something up, Google tries to find what search terms you’re interested in. These help Google analyze a popular search with the ones that you’re interested in.

In Google Trends, they have two types of related searches, top and rising.

Top searches are the most frequently searched with a keyword that you’ve put in.

Rising searches are queries which have had the most significant growth in a time period. …

As technology is taking a more prominent role in our daily lives, it’s important to think of real-world problems in a way that can be translated into an algorithm.

In this article, we’ll walk through the 4 steps of computational thinking described by BBC: decomposition, pattern recognition, abstraction, and algorithms, while solving the popular Leetcode problem, Two Sum.

Let’s break the problem into subproblems.

Since the length of the array we have to look through could be massive:

`2 <= nums.length <= 10⁴`

It’s probably not good to look at the array as a whole.

Here’s a comparison:

In [2…

Design is confusing, and after fumbling with your backend, it’s the last thing you want to worry about. Here are 3 tips to give your users the best experience possible!

Nobody likes an oversaturated interface, your design should define itself clearly.

One great example is Medium.com’s homepage.

This is great because:

- Navbar makes it easy to get around the site.
- Navbar is clear and concise. Nothing extra!
- Consistent font
- Clear message.
- Subtle colors.
- Speaks to both readers and authors.

I have annotated on the image below!

What you will learn:

- How to host your static website on Github Pages for free!

What you need:

- A static website to host!

To host your website on Github Pages, you need to have a Github account.

You can register for one here: https://github.com/join

Once you’ve signed up, you need to create a public repository.

After signing in to your Github account, there should be a sidebar with all of your repositories (if you have any) and a button where you can create one labeled “New”.

Click that button!

What you will learn:

- How to implement memoization in a Fibonacci function.

What you need:

- Nothing!

Recommended:

- Knowledge of a programming language.

A Fibonacci sequence is a sequence where the next number is the sum of the two before it, the first two numbers are 1.

First 5 numbers of Fibonacci:1, 1, 2, 3, 5

Every recursive function should have a base case, which makes sure that the function doesn’t call itself endlessly.

In this case, we’ll check if it’s 1 or 2, because we know that those two will have to be 1.

☝ The code stubs below…

What you will learn:

- How to convert a video to text using IBM’s Watson API and Python

What you need:

- Python installed on your computer.

We’ll need `ibm_watson`

to access IBM Watson services and `moviepy`

to strip the audio from a video.

# In command line or terminalpip install ibm-watson

pip install moviepy# In projectfrom ibm_watson import SpeechToTextV1

from ibm_cloud_sdk_core.authenticators import IAMAuthenticator, authenticator

import moviepy.editor as mp

We can define a `moviepy`

clip with `mp.VideoFileClip`

,

`clip = mp.VideoFileClip("VIDEO_PATH")`

and strip it using the `write_audiofile()`

function.

`clip.audio.write_audiofile("audio.wav")`

Now, our audio is prepared for translation!

You’ll have to have…