
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 33676 Articles for Programming

104 Views
In this article, we point to get details about the owner of a car. The program will ask the user to input the car enlistment number, and it'll recover the related information, such as the owner's title, address, and contact data. This program can be valuable in scenarios where car ownership data has to be rapidly accessed.Here we are going to use four different methods:PromptUserInput(), ValidateInput(registrationNumber string) bool, RetrieveOwnerDetails(registrationNumber string) (string, string, string), DisplayOwnerDetails(name, address, contact string) along with examples to elaborate the concept. Syntax func PromptUserInput() string The Syntax func PromptUserInput() string defines a function named PromptUserInput that ... Read More

616 Views
In this article, we are going to explore how to create a Go program that involves a slice of Person structs named People. The slice will contain a minimum of two elements, representing individuals with their respective names and addresses. By exploring the concept of slices and their usage in Go, we will learn how to effectively manage collections of data and perform operations on them. Let's dive in and explore how to work with slices in Go to handle a group of Person structs.Here we are going to use two different methods: using literal initialization and using the append ... Read More

376 Views
Throughout this article, we will dive into the details of implementing the PrintPerson function, understanding the structure of a Person, and executing the program to obtain the desired output. So, let's get started and learn how to utilize Go's features to print person details effectively. In this article, we will explore how to create a Go program that features a function called PrintPerson. Here we are going to use two different methods: using printin function and using printf function along with examples to elaborate the concept. Syntax printperson(person) This represents a function called printperson, and the person is an ... Read More

703 Views
Multithreading is a feature of the Java programming language that allows us to perform multiple operations simultaneously. In it, the operation gets divided into multiple smaller parts called a thread. Each thread performs one independent task without affecting the other thread's performance. The main benefit of multithreading is the optimal use of resources like CPU and it boosts the execution time of allocated operations. Finding prime and palindrome numbers are two of the basic programming task that every beginner programmer perfroms. However, in this article, we are going to do the same task in an exciting way. We will ... Read More

286 Views
In this go-language article, we are going to create an interface named Reader that defines the read method using direct interface implementation, and interface Composition along with examples to elaborate on the concept. A read method in go language is used to read the data from a source. Syntax sw.data It represents accessing the data of a struct. sw − it represents a variable, it can be a user defined struct variable or a pointer to struct. data − it is the name of the field you want to access. copy(p, sw.data[sw.pos:]) used to copy data ... Read More

2K+ Views
Memory management is an important aspect of any Java application. Having the knowledge of how much memory is available, how much is used and how much is free may help you to optimize your code and avoid performance issues or memory leaks. This article aims to help in finding max memory, free memory and total memory that are a crucial part of Java Heap. Note that the amount of memory allocated to a Java program depends on the environment. Java Program to find Max Memory, Free Memory and Total Memory Java provides the following methods and classes that ... Read More

138 Views
The work method in the go language is a user-defined method for custom data types to perform various operations. You can choose any name but functionality will depend on the specific requirement. The Worker interface can be executed by different sorts to supply distinctive usage of the Work behavior. Here we are going to use three different methods: direct interface implementation, struct embedding as well as interface assertion along with examples to elaborate the concept. In this article, we are going to investigate how to form an interface named Laborer in Go that indicates a Work strategy. Syntax type Animal ... Read More

301 Views
The speak method in golang is obtained by the customized functions that you can define to achieve a specific functionality. Speak is a user-defined function that performs the task for which it is created. In this article, we are going to create an animal interface that defines the speak method. This interface serves as a blueprint for any type that wants to be considered an animal and provides a contract for implementing the Speak behavior. Here we are going to use three different methods: direct interface implementation, struct embedding as well as interface assertion along with examples to elaborate the ... Read More

299 Views
In Go, channels are a capable highlight for concurrent programming, empowering communication and synchronization between goroutines. In this article, we are going to investigate how to form a channel of sort string in Go and utilize a goroutine to send messages to the channel at normal intervals of 2 seconds. We are going to give a step-by-step exhibit of the program, displaying the utilization of channels and goroutines. Syntax time.NewTicker(time.Second) The Syntax time.NewTicker(time.Second) is used to create a new Ticker value from the time package in Go. time.Sleep(duration) The Syntax time.Sleep(duration) is used to pause the execution of a ... Read More

460 Views
A binary tree is a tree having at most two children whereas a binary search tree is the tree in which the elements in the left side of the tree are less than the elements in the right side of the tree. In this article, we will write Go language programs to check if a binary tree is a binary search tree. Here we will use different examples to provide a better understanding of the concept. Algorithm Step 1 − Create a Node struct with three fields the data of the node of type int, Left and right subtree ... Read More