Skip to content

Programming Articles

  • HOME
  • Python
  • JavaScript
  • C/C++
  • Java
  • Terms & Conditions and Privacy Policy
  • About US
Main Menu
How to sort a list in Python
Latest / Python HowTos

How to sort a list in Python

In this article, we’ll learn how to sort list, list of dictionaries, and list of tuples in Python. We can sort lists, lists of tuples, and list of dictionaries in …

How to sort a list in Python Learn More
how to extract numbers from a string in C
C Examples / C/C++

How to extract numbers from a string in C?

In this article, you’ll learn how to get numbers from a string in C with examples. There are many ways to do that, but my favorite a recommended method is …

How to extract numbers from a string in C? Learn More
Latest / Linux

Is Linux an Operating System?

This article answers one of the most asked questions, “Is Linux an operating system?”. Most of it is discussed in the history of Linux and UNIX, where I explained how …

Is Linux an Operating System? Learn More
History of UNIX
FEATURED / Latest / Linux

From UNIX to Linux – History of Linux

You’ve probably heard about Linux or at least the word Linux. You might even know it’s an operating system, in fact, it’s the kernel used at the heart of the …

From UNIX to Linux – History of Linux Learn More
Top themes for Ubuntu
FEATURED / Linux

Best themes for Ubuntu: Make Ubuntu Beautiful

In this article, you’ll learn about the best themes for Ubuntu and how to install themes on Ubuntu to create a cool Ubuntu desktop using available themes. Linux is all …

Best themes for Ubuntu: Make Ubuntu Beautiful Learn More
C Examples / Examples

C program to delete an element from an array

This C program takes the position as input from the user and deletes the element of array at that position.In this program, the original array and its size is also …

C program to delete an element from an array Learn More
C Examples / Examples

Insertion sort in C

In this post, you’ll learn about the insertion sort algorithm in C and how to implement it in the C programming language with and without a function using example programs. …

Insertion sort in C Learn More
C Examples / Examples

Selection sort in C

In this article, you’ll learn about the selection sort algorithm and its implementation program in the C programming language with and without a function in easiest possible way. Selection sort …

Selection sort in C Learn More
C Examples / Examples

Bubble sort in C

In this article, you’ll learn about the bubble sort algorithm and how to implement it in the C programming language with and without a function in easiest way. Bubble sort …

Bubble sort in C Learn More
Data types in Python
Python

Data types in python | Python tutorial

There are mainly 7 data types in python: Numerical String List Tuple Dictionary Set Range Let’s try to understand these data types. 1. Numerical data types Numerical data types mainly …

Data types in python | Python tutorial Learn More
Strings in Python
FEATURED / Python

Strings in Python

string in python is one of the most important and interesting data type. . .

Strings in Python Learn More
Install VS Code in Ubuntu
How To / Linux

How to install Visual Studio Code on Ubuntu?

Microsoft’s Visual Studio Code is the IDE for both novice and professional software/application developers. It is very easy to use and no expensive resources are required to run this IDE. …

How to install Visual Studio Code on Ubuntu? Learn More
Getting started with Python
Python

Learn Python programming- Getting started

This article covers the most common query – How to start programming in python? Start python by running the Python interactive prompt.Just type python (or python3 if you’ve both python …

Learn Python programming- Getting started Learn More
is python hard to learn
FEATURED / Latest / Python

Is Python hard to learn? Top best learning resources

Is python hard to learn? How long to learn python? Is python easy to learn? there are many similar questions that come to one’s mind while starting to learn python. This article will clear your all the doubts related to the language and you’ll get the best resources to learn python at the end.

Is Python hard to learn? Top best learning resources Learn More
General

What is the “N+1 selects problem” in ORM (Object-Relational Mapping)?

Let’s say you have a collection of Car objects (database rows), and each Car has a collection of Wheel objects (also rows). In other words, Car → Wheel is a 1-to-many relationship. Now, let’s say you need to iterate through …

What is the “N+1 selects problem” in ORM (Object-Relational Mapping)? Learn More
Git / SSH

Could not open a connection to your authentication agent: Error resolved

Did You Start ssh-agent? You might need to start ssh-agent before you run the ssh-add command: Note that this will start the agent for msysgit Bash on Windows. If you’re using a different shell or operating …

Could not open a connection to your authentication agent: Error resolved Learn More
Git

How to name and retrieve a stash by name in git?

This is how you do it: Where “my_stash” is the stash name. Some more useful things to know: All the stashes are stored in a stack. Type: This will list down all …

How to name and retrieve a stash by name in git? Learn More
Python HowTos

How to remove an element from a list by index in Python?

Use del and specify the index of the element you want to delete: Also supports slices: How to remove an element from a list by index in Python? You probably want pop: By …

How to remove an element from a list by index in Python? Learn More
Git

How to remove a file from the last commit in Git?

This is a question of moving the mistakenly committed files back to the staging area from the previous commit, without canceling the changes done to them. This can be done …

How to remove a file from the last commit in Git? Learn More
Java

How to break out of nested loops in Java?

Technically the correct answer is to label the outer loop. In practice if you want to exit at any point inside an inner loop then you would be better off …

How to break out of nested loops in Java? Learn More
Git

How to stash a specific file in Git?

Since git 2.13, there is a command to save a specific path to the stash: git stash push <path>. For example: OLD ANSWER: You can do that using git stash –patch (or git stash …

How to stash a specific file in Git? Learn More
JavaScript

How to copy array by value in JavaScript?

Use this: Basically, the slice() operation clones the array and returns a reference to a new array. Also note that: For references, strings and numbers (and not the actual object), slice() copies object references …

How to copy array by value in JavaScript? Learn More
Git

When to use Git rebase instead of Git merge?

Short Version Merge takes all the changes in one branch and merges them into another branch in one commit. Rebase says I want the point at which I branched to …

When to use Git rebase instead of Git merge? Learn More
Pandas

How to update the value of a row in a Python Dataframe?

In this article, we’ll learn how to update the value of a row in a Python Dataframe. If you want a direct answer and are not interested in the explanation …

How to update the value of a row in a Python Dataframe? Learn More
ReactJs

How to programmatically navigate using React router?

For those who are already using React Router v6, this can be done using useNavigate hook provided by react-router. Navigation with this hook is pretty simple: For a detailed answer, keep reading. How …

How to programmatically navigate using React router? Learn More
Python HowTos

How to determine the type of an object in Python?

There are two built-in functions that help you identify the type of an object. You can use type() if you need the exact type of an object, and isinstance() to check an object’s type against something. …

How to determine the type of an object in Python? Learn More
Python

How to read a file line-by-line into a list in Python?

This code will read the entire file into memory and remove all whitespace characters (newlines and spaces) from the end of each line: If you’re working with a large file, …

How to read a file line-by-line into a list in Python? Learn More
Git

How to cache HTTPS credentials for pushing commits?

This article explains how to save HTTPS credentials for pushing commits or in other words, permanently authenticating to git repositories. Since Git 1.7.9 (released 2012), there is a neat mechanism …

How to cache HTTPS credentials for pushing commits? Learn More
DB-SQL/Postgresql/MongoDB

How to return only the Date from a SQL Server DateTime datatype?

Here’s your solution: for example gives me Pros: No varchar<->datetime conversions required No need to think about locale How to get only the Date from a SQL Server DateTime datatype? …

How to return only the Date from a SQL Server DateTime datatype? Learn More
JavaScript

How to add new elements at the beginning of an array in JavaScript?

Use unshift to add new elements at the beginning of an array. It’s like push, except it adds elements to the beginning of the array instead of the end. unshift/push – add an …

How to add new elements at the beginning of an array in JavaScript? Learn More
HTML / JavaScript

How to retrieve the position (X,Y) of an HTML element using JavaScript?

The correct approach is to use element.getBoundingClientRect(): Internet Explorer has supported this for as long as you are likely to care about and it was finally standardized in CSSOM Views. All other browsers …

How to retrieve the position (X,Y) of an HTML element using JavaScript? Learn More

Posts navigation

1 2 … 27 Next

Featured Posts

History of UNIX

From UNIX to Linux – History of Linux

21st November 202013th November 2021

Top themes for Ubuntu

Best themes for Ubuntu: Make Ubuntu Beautiful

20th October 202029th November 2021

Strings in Python

Strings in Python

12th September 202010th November 2021

is python hard to learn

Is Python hard to learn? Top best learning resources

18th April 202013th November 2021

Recent posts

  • What is the “N+1 selects problem” in ORM (Object-Relational Mapping)?
  • Could not open a connection to your authentication agent: Error resolved
  • How to name and retrieve a stash by name in git?
  • How to remove an element from a list by index in Python?
  • How to remove a file from the last commit in Git?
  • How to break out of nested loops in Java?
Copyright © 2022 Programming Articles.
Powered by WordPress and HitMag.