Insertion sort is very popular sorting algorithms because of its simplicity. Its performance is not as good as quicksort or shellsort for large array but it is very simple like bubble sort. It is often used for less number of elements especially when the array is substantially sorted. Here we’ll see how to implement insertion sort in … Continue reading “How to Implement Insertion Sort in C Programming?”
Tag: C Programming
Parse and Print XML File in Tree Form using libxml2 in C
XML file is widely used format to store and transport data over internet. Parsing XML file is a very basic programming requirement. Here we’ll see how to parse and print the content of an XML file in C programming language. XML File Format Before jumping into the code, we should understand basic format of an … Continue reading “Parse and Print XML File in Tree Form using libxml2 in C”
How to Remove Duplicate Entries from Linked List?
Here we’ll see how to write C program to remove duplicate entries from linked list. Linked list contains duplicate entries when nodes with same value appear multiple times in the list. In the above Linked list entries, 43, 24 and 5 appeared more than once. We’ll write a C program to remove these duplicate elements … Continue reading “How to Remove Duplicate Entries from Linked List?”
C Program to Implement a Singly Linked List
What is Singly Linked List? Linked List is a collection of interconnected nodes that together represent a sequence. Connected node means if you have access of a node, then you can get access to the next nodes even though they are not located in consecutive memory locations. For singly linked list, you can traverse the … Continue reading “C Program to Implement a Singly Linked List”
How to Access MySQL Database from C Program?
MySQL is an open sourcce database management system (DBMS). It is very popular among the web developers as it is part of LAMP (Linux, Apache, MySQL, PHP/Perl/Python) stack. Many popular large scale websites like WikiPedia, Facebook, Youtube use this database. Many times we need to use access MySQL database from C program. Here we’ll see … Continue reading “How to Access MySQL Database from C Program?”