Aditya Chatterjee's Blog, page 53
February 17, 2023
Convert integer to string in C++ [3 methods]
In this article, we will convert integer to string in C++ using different methods.
Table of Contents:
Integer to string conversion by to_string() method.Integer to string conversion by stringstream class.Integer to string conversion by using boost::lexical_cast.Method 1. By to_string() methodIn C++, the std::string to_string( int value ) function is a built in function, which simply returns the integer value to string after conversion.
It is defined in the header file
We can also use to_s...
February 16, 2023
vector::capacity() function in C++
In this article, we will discuss about the vector::capacity() function in C++ and why it is essential when working with vectors.
Table of Contents:
Introduction to vector::capacity() functionSyntax and Time Complexity of the vector::capacity() functionExamples1. Introduction to vector::capacity() functionIn C++, the vector::capacity() function is a built in function, which simply returns the maximum capacity that is allocated by the vector.
2. Syntax and Time complexity of the vector::capa...Convert array to list in Java [4 methods]
In Java, arrays and lists are two fundamental data structures. Arrays have a fixed length and are used to store a collection of elements of the same type. Lists, on the other hand, are dynamic and can grow or shrink as needed to store a collection of elements. In Java, it is often necessary to convert an array to a list or vice versa. In this article, we will explore several ways to convert an array to a list in Java.
Pre-requisites:
Array Data StructureList in JavaTable of contents:
Using ...February 15, 2023
Biomedical Image Segmentation

Image segmentation is the process of partitioning a certain image into several regions of interest (ROI). In the Biomedical field segmented images can be used for anomaly detection, diagnosing diseases, computer-integrated surgery, treatment planning, studying anatomical structures, and much more. One of the advantages of having automated image segmentation methods is it’s not expensive and requires less work compared to manual segmentation. Automated image segmentation, when built ...
Tracking cursor using JavaScript
In this article, I will show you how to keep track of the cursor position with a timestamp and download the data into a text file.
Table of contents:
Demo
HTML structure
Styles with CSS
JavaScript functionality:
cursor positiontext file creation1. Demo
X:
Y:
Timestamp:
Download fileThe HTML structure is ve...
GUI in Java [Complete Practical Guide]
In this article, we learn about GUI in Java with Java AWT, Swing, JavaFX, and some other relevant concepts.
We'll discuss:
IntrdoductionJava AWT (Absract Window Toolkit)Java SwingJavaFXCreating LayoutIntroductionBorderLayoutFlowLayoutGridLayoutEvent HandlingWorking with Images and Audio FilesConclusion
Graphical User Interface (GUI) is an essential part of modern software development. It provides a visual interface for users to interact with the computer and access its functi...
Stopwatch application in HTML/ JavaScript
TABLE OF CONTENTS:
IntroductionStep 1: Create the simple structure of the stopwatchStep 2: Create the display to see the timeStep 3: Create buttons in Stopwatch using HTML CSSStep 4: Activate the Stopwatch using JavaScriptIntroductionIn this article, we will create a stopwatch/ countdown timer using JavaScript. Basically what we need is a HTML CSS and JavaScript file. The StopWatch uses three buttons which are Start, Pause and Reset. The buttons are used to start, pause and reset the Sto...
February 13, 2023
Ruby on Rails app to demonstrate database concepts
On this post, we’ll talk about the most popular databases in RoR web development, walk you through the process of integrating them, and describe the best practices.
In this tutorial we will build a static page with a button CreateTimeline which when clicked makes a record with the current time. On another page, the recent clicks as rows and total number of clicks will be displayed. We will add a delete button with each click row.
A database is a file that stores organized infor...
Find the rightmost set bit in a number (+ toggle it)
Finding the rightmost set bit in a number is a common problem in computer science and is used in many applications, from competitive programming to low-level programming and data compression. In this article, we will explore various techniques to find the rightmost set bit in a number, including bitwise operations and mathematical approaches.
Table of Contents̥What is a Set bitUnderstanding bit wise AND (&)Methods3.1 Using right shift (>>)
3.2 Using left shift (3.3 Using 2's complementApp...
February 12, 2023
Multi-Layer Perceptron (MLP): A Basic Understanding
Multi Layer Perceptron (MLP) is a type of artificial neural network that is widely used for various machine learning tasks such as classification and regression. It is called a multi-layered perceptron because it has many layers of nodes (known as artificial neurons) that connect to each other. In this article, we will explore the main features and components of MLP, its architectural and training processes, and its programs in various fields.
HistoryMLP was first introduced in the...