Aditya Chatterjee's Blog, page 25
July 14, 2023
Queue Data Structure in JavaScript [with OOP]
In the realm of computer science, data structures play a vital role in organizing and manipulating data efficiently. One such data structure is the queue. A queue is an abstract data type that follows the First-In-First-Out (FIFO) principle. JavaScript, being a versatile programming language, provides built-in support for implementing queues.
In this article at OpenGenus, we will delve into the queue data structure in JavaScript, understand its underlying principles, and learn how to implement a...
Merge Sort in Python [with OOP, Iterative + Recursive]
Sorting is a fundamental computer science operation that allows us to organize data in a specified order for efficient searching, analysis, and processing. There have been several sorting algorithms invented, each with its unique set of benefits and qualities. Merge sort is on...
July 11, 2023
Linguistic Data Mining and Corpus Linguistics

Linguistic Data Mining and Corpus Linguistics are two interrelated fields of computational linguistics that have gained significant attention in recent years. Corpus linguistics focuses on the systematic analysis of linguistic corpora to investigate various aspects of language, such as its structure, usage patterns and linguistic variation. Whereas, linguistic data mining involves extracting valuable information and patterns from large linguistic datasets. The following article provides...
July 7, 2023
Map::swap() in C++

Table of content:
Introduction to MapsDetailed view of Map::swap()Syntax to swap two MapsExamples to swap two mapsTime and Space complexityApplicationQuestionsIntroduction to MapsIn C++, a map is an associative container provided by the Standard Template Library (STL) that stores elements in a sorted manner, allowing for efficient searching. It has a time complexity of O(log n) for operations like insertion, deletion, and search.
A map stores elements in a mapped manner, where each ele...
July 1, 2023
Memory Game using JS and HTML
In this article at OpenGenus, we will look into implementing a memory game using JS and HTML.
ContentsGame and the rules.Design Overview and Approach.Folder structure.Implementationindex.htmlstyle.cssscript.jsGamePlay.Game and the rulesMemory game is a fun way to pass the time. In this, the player chooses 2 random tiles or cards depending on the way the game is implemented. A player has to match 2 cards and if he can successfully match all the cards, he will win.
Rules:
The playe...June 29, 2023
Doubly Linked List in C++ using OOP and Template
Table of contents:
IntroductionWhat is a Doubly Linked List?OOP BasicsTemplateUseful ApplicationsImplementing a Doubly Linked List Using OOP and TemplateQuestionsReading time: 15 minutes
IntroductionA doubly linked list is an extremely useful data structure that can permit forward and backward traversal of a list. This method of traversal is what makes it very unique and desirable in many situations.
In this article at OpenGenus, we will review how we can utilize OOP and templates to ...
Kafka Architecture and Importance
In this article at OpenGenus, we will be looking at the architecture of Kafka and its importance.
Overview of the article,
Why?Event.Streaming Platform.Kafka.Kafka Components.Message.Topic.Partition.Cluster.ZooKeeperProducers.Consumers.Importance.Realtime Usecase.Why?Let's start with why?
Here, we have many data sources in our lives, it could range from different devices to stores etc depending on the type of business at hand. Generally, as a business, we take the data to our op...
June 27, 2023
Building your own GPT code assistant
In this article, we have explored how one can build their own GPT code assistant that is Code generation using GPT model architecture.
Table of contents:
I. Introduction to GPT
II. Transformers and NLP
III. Build your own Python code generator
IV. References
"GPT" has quickly achieved the buzzword status in the AI field, but what is GPT? Why is the developer community going crazy over it? How has it changed machine learning in recent years? Can you train GPT on your own data...
June 25, 2023
Tool to convert Article to summary and audio with translation feature
This article at OpenGenus shall aim to serve as an introduction to a prototype of the Article Convertor, Summarizer and Translator Tool developed by Ambarish Deb for OpenGenus IQ, as part of internship program. We shall go through the entire scope of the product, starting from the need behind said product, it's initialization and then each of its use cases and their implementation.
Role Fulfilled by this ToolNowadays, there is no dearth of quality articles available online on multiple subjects ...
June 24, 2023
Arithmetic coding (encoding + decoding)
Table of contents:
Arithmetic coding (Encoding)Arithmetic coding (Decoding)Example (Encoding)Example (Decoding)Implementation (encoding and decoding)Time ComplexityApplicationQuestionArithmetic coding (Encoding)Arithmetic coding is a sophisticated method to compress data based on the probability of occurrence of each unique symbol in a message.
To encode a message, we can do as follows:
Step 1: Calculate the frequency of occurrences of each unique character/ symbol in the message. Th...