09 December 2016 5 minutes

How to Use WordNet in Node.js Applications

Written by Ashraff Hathibelagal
  Programming

If you are creating an application that needs some form of natural language processing, you'll probably want to use WordNet. If you aren't familiar with it already, you can think of WordNet as a huge database of English words, their synonyms, definitions, and parts of speech. In this tutorial, I'm going to show you how to create a simple English-English dictionary application, that queries the WordNet database via wordnet-db and natural, which are popular Node.js packages...

Read more »
07 December 2016 20 minutes

Displaying GIFs and Large Images in Android Apps Using Facebook Fresco

Written by Ashraff Hathibelagal
  Programming

Handling large images in Android apps has always been a little tricky. With Facebook Fresco, however, you can add huge images to your app, including animated GIFs and WebP files, without having to worry about memory and size issues. In this tutorial, I'm going to help you get started with it...

Read more »
30 November 2016 2 minutes

Creating Whiteboard Animations With jsWritingTool

Written by Ashraff Hathibelagal
  Design

Most of us are familiar with the handwritten animation effect, which can be seen in many Youtube videos—mostly videos that are explaining something. Creating such videos has always meant using tools that are quite expensive. So, I decided to create a free tool that requires no registration and no downloads whatsoever...

Read more »
12 November 2016 20 minutes

How to Create an Imgur Client for Android

Written by Ashraff Hathibelagal
  Programming

Imgur has a very powerful and easy-to-use API that allows you to programmatically access all its photos and albums. In this tutorial, I'm going to show you how to use it to create a simple Imgur client for Android. It's going to be a native application. So, we'll be working with the Android SDK and a few third-party Android libraries...

Read more »
26 October 2016 10 minutes

Getting Started With NLP_Compromise

Written by Ashraff Hathibelagal
  Programming

Natural Language Processing, often shortened to just NLP, is becoming increasingly popular these days. Fortunately, there are several JavaScript libraries that facilitate NLP. In this tutorial, I'll be talking about one such library, called NLP_Compromise. It is fast, light-weight, and has a very intuitive API. It also enjoys a lot popularity among JavaScript developers...

Read more »
16 October 2016 10 minutes

How to Create Fractal Trees Using JavaScript

Written by Ashraff Hathibelagal
  Programming

Did you know that trees--I'm talking about the ones you find in a jungle, not those that are in an algorithms book--too behave like fractals? If you step out of your room and take a close look at any old tree in your garden or neighborhood, you'll notice that most of its branches are quite similar to each other. They might not be exactly like one another, but they definitely share patterns. In this tutorial, I show you how to procedurally generate trees using JavaScript...

Read more »
14 October 2016 10 minutes

How to Create a Koch Curve Using JavaScript

Written by Ashraff Hathibelagal
  Programming

If you've had an opportunity to observe them closely, I'm sure you'd agree with me when I say that fractal patterns are incredibly fascinating and awe-inspiring. Even though they look so complex, writing programs to generate them takes very little time and effort. In this tutorial, I show you how to create one of the simplest fractals we know. It's called a Koch curve. I'm not going to get in to its theory--the Wikipedia article covers all of it. Instead, I'm going to focus on creating it is using just JavaScript and the HTML5 canvas...

Read more »
12 October 2016 10 minutes

How to Use Tesseract.js, an OCR Engine for the Browser

Written by Ashraff Hathibelagal
  Programming

Optical Character Recognition, often shortened to just OCR, has been around for a very long time. However, because OCR is a CPU-intensive task, it has been limited to native desktop applications or server-side programs. Tesseract.js is a lightweight JavaScript library that tries to bring OCR to the browser. It is quite accurate, and supports well over a dozen languages...

Read more »
03 October 2016 20 minutes

How to Use Reddit OAuth 2.0 In Android Apps

Written by Ashraff Hathibelagal
  Programming

If you are building an Android client for Reddit, you cannot ask your users to type in their usernames and passwords directly into your app. Well, you could a few years ago, but not anymore. Reddit now expects all its mobile clients to follow the OAuth 2.0 protocol. Adding the OAuth flow to an Android app, however, is no trivial task. Last week, I spent about an hour learning how to implement it. By writing this tutorial, I hope to help you save some time...

Read more »
28 September 2016 5 minutes

How to Create a Reddit Bot Using PRAW4 In 5 Minutes

Written by Ashraff Hathibelagal
  Programming

Whether you like it or not, a significant number of Reddit users are bots. Usually, they perform just two tasks--they look for comments that match a few well-defined criteria and then automatically reply to them. Creating such bots takes less than 5 minutes if you know how to use Python...

Read more »