You are on page 1of 328

Scanned by CamScanner

Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Module 3:Linked List
Definition: The linked list is a linear data structure consists of nodes which are created dynamically. Each node of the linked list
is having 2 parts one is info part(data) and another is link(next) part.

1. Info: it contains information of data element


2. Link: it is a pointer variable which holds the address of the next node.

In the linked list there exists a special pointer called START (HEAD) which holds the address of the first node.

Initial value of START = NULL.

Example:

A linked list is a dynamic data structure. The number of nodes in a list is not fixed and can grow and shrink on demand. Any
application which has to deal with an unknown number of objects will need to use a linked list.

Arrays:

Advantages

1. data accessing is fast.


2. Arrays are simple to understand and use.

Disadvantage

1. The size of the array is fixed. The upper limit on the array size should be known.
2. Array elements are stored contiguously.
3. Insertion and deletion operation in an array is expensive.

Advantages of Linked List

1. In linked list, nodes are created dynamically so the list can grow and shrink during the execution of program.
2. Insertion and deletion operations are easier and efficient.

Disadvantages of Linked List

1. For storing a given information it requires the space for the information and the space for the link part as well. For ex: if
you want to store 5 floating point kind information in a linked list, then the total number of bytes we required is (5 X 6) +
2 = 32 bytes, whereas if we store the same in an array it requires (5 X 4) = 20 bytes which is less than 32 bytes.

Representation of linked list in memory:-

Consider the link list as follows

Here 102,501,203,105 are the memory location of nodes. For representing the above link list memory, two linear arrays are
required. i)info ii)link
START INFO LINK
5 1 1
2 E 2 NULL
3 C 3 11
4 4
5 A 5 9
6 6
7 7
8 8
9 B 9 3
10 10
11 D 11 2
12 12

Declaration of Nodes

struct node{
int info;
struct node *next;
};

NOTE: Node may have more than one information part.


Example:
struct node{
int age;
char name[20];
float sal;
struct node *next;
};

Garbage collection:

The memory allocation for the objects is done from the heap. If some object is created and which is not been in use from a long time
then such an object is called garbage. The garbage collection is a technique in which all such garbage is collected and recycled. The
garbage collector cleans up the heap so that the memory occupied by the unused objects can be freed and can be used allocating for
the New objects. The garbage collection algorithm works in two steps as follows:

1.MARK- In the marking process all the live object are located and marked them as non-collected objects.

2.SWEEP- In this step, all the unmarked object are swept from the heap and the space that has been allocated by these objects can
be used for allocating new objects.

But the drawback of this mark and sweep algorithm is that multiple fragments of memory get created hence the technique called
compaction is used. In compaction technique the allocated space is moved up to form a contiguous block of free space in the heap.

Operations on Linked List


The basic operations on link list are as follows
1. Creation : Creation of link list
2. Insertion:.
a. At the beginning of link list
b. At the end of link list
c. At the specified position
3. Deletion
a. At the beginning of link list
b. At the end of link list
c. At the specified position
4. Traversing: visiting each node exactly once, it may be for displaying, counting, searching etc
5. Concatenation: it is a process of appending(joining) the second list to the end of list consisting of m nodes. When we
concatenate 2 lists, the 2nd list has ‘n’ nodes then the concatenated list will be having m+n nodes.
Types of linked list
1. Single link list
2. Double link list
3. Circular link list
4. Header link list

Single linked list


Creation of Link List
void create(){
int ch;
do{
new1 = (struct node*) malloc (sizeof(struct node));
if(new1 = = NULL)
{
printf(“memory is not available”);
exit();
}
printf(“Enter the item into the node”);
scanf(“%d”,&new1→info);
new1→link = NULL;
new1→link=start;
printf(“Enter your choice”);
printf(“1 for continuing”);
printf(“0 for stop creating”);
scanf(“%d”,&ch);
}(while ch!=0);
}

/* write a program for the creation of node having one information part */
#include <stdio.h>
#include<conio.h>
#include<alloc.h>
Struct node
{
int info;
struct node *link;
};
Struct node *start=NULL;
Struct node *new1;
void main()
{
int i,n;
printf(“Enter the no of nodes you want to create in the link list”);
scanf(“%d”,&n);
void create_list();
for(int i=0;i<n;i++)
create_list();
getch();
}
void create_list()
{
new1 = (struct node*) malloc (sizeof(struct node));
if(new1 = = NULL)
{
printf(“memory is not available”);
exit();
}
printf(“Enter the information part of the node”);
scanf(“%d”,&new1→info);
new1→link = NULL;
new1→link=start;
start = new1;
}

/* write a program for the creation of node having more than one information part */
#include <stdio.h>
#include<conio.h>
#include<alloc.h>
Struct node
{
int age;
int sal;
char name[15];
struct node *link;
};
Struct node *start=NULL;
Struct node *new1;
void main()
{
int I,n;
clrscr();
printf(“Enter the no of nodes you want to create in the link list”);
scanf(“%d”,&n);
void create_list();
for(int i=0;i<n;i++)
create_list();
getch();
}
void create_list()
{
int ch;
int c;
do{
new1 = (struct node*) malloc (sizeof(struct node));
if(new1 = = NULL)
{
printf(“memory is not available”);
exit();
}
printf(“Enter the information part of the node”);
printf(“Enter the age, salary”);
scanf(“%d %d”,&new1→age, &new1→sal);
printf(“Enter the name”);
scanf(“%n”, name);
new1→link = NULL;
new1→link=start;
start = new1;
c++;
printf(“Enter your choice”);
printf(“1. For creation of another node\n”);
printf(“2 Enter ‘0’ to stop the creation of node\n”);
scanf(“%d”,&ch);
}while(ch!=0);
printf(“The no of nodes created is %d”,c);
}
void main(){
clrscr();
create_list();
getch();
}

Inserting a node to link list


C-Program
void insert_listnode()
{
struct node *new1;
new1= (struct node*) malloc(sizeof( struct node));
if(new1 == NULL)
{
printf("overflow");
exit();
}
else{
printf("enter the item to be inserted as list node");
scanf(%d",&new1-->info);
new1-->link = NULL;
new1-->link = start;
start = new1;
}
}

Inserting a node as last node


void insert_lastnode()
{
struct node *new1, *temp;
new1= (struct node*) malloc(sizeof( struct node));
if(new1 == NULL)
{
printf("overflow");
}
else{
printf("enter the item to be inserted as list node");
scanf(%d",&new1-->info);
new1-->link = NULL;
if(start == NULL)
start = new1;
else{
for(temp=start;temp-->link != NULL;temp = temp-->link){
temp-->link = new1;
}
}
}

Traversing a link list


void traverse()
{
struct node *temp;
if(start = = NULL)
printf("List is empty");
else
{
for(temp= start;temp!=NULL;temp = temp-->link)
printf("%d",temp-->info);
}
}

Traversing the linked list in reverse order

void reverse_traverse()
{
int a[30],i=0;
struct node *start;
struct node *temp;
for(temp= start;temp!=NULL;temp = temp->link)
{
a[i] = temp->info;
i++;
}
i--;
while(i>=0){
printf("%d",a[i]);
i = i+1;
}
}
Searching an element in link list
void searching()
{
if(start = = NULL)
{
printf("list is empty");
exit();
}
temp = start;
while(temp!=NULL && temp->info!=item)
temp = temp->link;
if(temp->info = = item)
{
printf("item is found");
}
if(temp = = NULL){
printf("Item is not found");
}
}

Write an algorithm/program for counting the number of nodes in the link list
C-Procedure

void count()
{
int c;
struct node * temp;
if(start = = '\0')
printf("underflow");
else{
for(temp=start;temp!=NULL;temp = temp->link)
c++;
}
printf("the no of nodes present in the list is=%d", c);
}

Sorting in single link list


void sort(){
//start, link, info are defined as global variables;
int num;
struct node * temp1, *temp2;
for(temp1=start;temp1!="NULL";temp1 = temp1->link)
for(temp2=start;temp2!="NULL";temp2 = temp2->link)
if(temp1->info > temp2->info)
{
num = temp1->info;
temp1->info = temp2->info;
temp2->info = num;
}
}

Concatenation of two link list

void concatenate()
{
//start1, start2, link, list1, list2 has been declared as global variables
struct node *temp;
for(temp = start1;temp->link!='\0'; temp= temp->link);
temp->link = start2;
start2 = "NULL";
}

Insertion of node at a given position

void insert_atpos(){
int i, c=0, pos;
struct node *temp;
printf("Enter the position where the node has to be inserted\n");
scanf("%d,&pos);
new1= (struct node*) malloc(sizeof( struct node));
if(new1 == NULL)
{
printf("overflow");
}
else{
printf("enter the item to be inserted as list node");
scanf(%d",&new1-->info);
new1-->link = NULL;
}
// code for checking validity of position
for(temp=start;temp-->link != '\0';temp = temp-->link)
c++;
if(pos>c+1)
{
printf("invalid position");
exit();
}
if(pos = = 1)
{
new1->link = start;
start = new;
}else if(pos = = c+1)
{
for(temp=start; temp->link!='\0';temp=temp->link);
temp->link = new1;
}else{
i=1;
temp=start;
while(i<pos-1)
{
temp = temp->link;
i = i+1;
}
new1->link = temp->link;
temp->link = new1;
}
}

Deletion
Deletion of 1st Node
void delete_1st_node(){
struct node *temp;
if(start = =NULL)
{
printf("underflow");
exit();
}
temp = start;
if(temp->link = = NULL)
{
start = NULL;
free(temp);
}else{
start = temp->link;
temp->link = NULL;
free(temp);
}
}
Deletion of Last Node

void delete_last(){
struct node *temp, *prev;
if(start = =NULL)
printf("underflow");
if(start->link = = '\0')
{
temp = start;
start = '\0';
free(temp);
}else{
for(temp = start;temp->link!='\0';temp=temp->link)
{
prev=temp;
}
prev->link = NULL;
free(temp);
}
}

Deletion of node at a given position

void delete_at_pos(){
int i, c=0, pos;
struct node *prev, *temp;
printf("Enter the position where the node has to be deleted\n");
scanf("%d,&pos);
if(start == '\0')
{
printf("overflow");
exit();
}
// code for checking validity of position
for(temp=start;temp-->link != '\0';temp = temp-->link)
c++;
if(pos>c)
{
printf("invalid position");
exit();
}
if(pos = = 1)
{
if(start->link = ='\0')
{
temp = start;
start = NULL;
free(temp);
}
else{
temp = start;
start = temp->link;
temp_.link = '\0';
free(temp);
}
}
}else if(pos = = c)
{
for(temp=start; temp->link!='\0';temp=temp->link);\{
prev = temp;
}
prev->link = '\0';
free(temp);
}
}else{
prev = '\0';
temp = start;
for(i=1;i<pos;i++)
{
prev = temp;
temp = temp->link;
}
prev->link = temp->link;
temp->link = '\0';
free(temp);
}

CIRCULAR LINK LIST


It is a type of linear list in which next position field of the last node contains the address of the first node rather than the NULL
pointer.
Two types of circular link list are there.
1.single circular link list.
2.double circular link list.

1.Single circular link list:


In case of single circular link list, the last node points back to the first node i.e., the last node holds the address of first node
instead of containing NULL pointer.
Representation of single circular link list: [Refer class notes]
Condition for underflow:
If the list is empty then start must hold NULL. So if(start==NULL) then undeflow.
Condition for overflow:
if(new1==NULL) then overflow
Condition for existance of single node:
If there exist a single node in the list then the next part or next pointer field of that node holds the address of itself.
if(start=start-->link) then single node is present in the list.

Creation of single circular link list:


void create_cll()
{
//start,info and link are declared as global variable
struct node *temp, *new1;
int ch,c=0;
do
{
new1=(struct node *)malloc(sizeof(struct node));
if(new1==NULL)
{
printf("overflow");
exit();
}
else
{
new1-->link=NULL;
printf("Enter the information part of the node\n");
scanf("%d",&new1-->info);
new1-->link=start;
start=new1;
c=c+1;
}
printf("Enter your choice\n");
printf("1.For creation \n 0. To stop\n");
}while(ch!=0);
temp=start;
while(temp-->link!=NULL)
temp=temp-->link;
temp-->link=start;
printf("The no of nodes created are %d",c);
}

Traversal of single circular link list:


void display()
{
//start, info,link have been declared as global variable
struct node *temp;
if(start==NULL)
{
printf("The list is empty");
exit();
}
else
{
temp=start;
do{
printf("%d-->",temp-->info);
temp=temp-->link;
}while(temp!=start);
printf("%u",start);
}
}
NOTE: Other operations that can be performed in single circular link list are: searching, sorting, insertion, deletion etc.
Insertion in single circular link list:
A) Insertion at first position:
void insert_at_first()
{
//start,info and link are declared as global variable
struct node *new1, *temp;
new1=(struct node *)malloc(sizeof(struct node));
if(new1==NULL)
{
printf("overflow");
exit();
}
else
{
printf("Enter the information part of the node");
scanf("%d",&new1-->info);
new1-->link=NULL;
if(start==NULL)
{
new1-->link=new1;
start=new1;
}
else
{
new1-->link=start;
start=new1;
temp=start-->link;
while(temp-->link!=start-->link)
temp=temp-->link;
temp-->link=new1;
}
}
}
NOTE: After inserting new node, traversal operation is performed. If we will traverse before insertion then else part will be
executed.
temp=start;
while(temp-->link!=start)
temp=temp-->link;
temp-->link=new1;
new1-->link=start;
start=new1;

B)Insertion at last position:


void insert_at_last()
{
//start,info and link are declared as global variable
struct node *new1, *temp;
new1=(struct node *)malloc(sizeof(struct node));
if(new1==NULL)
{
printf("overflow");
exit();
}
else
{
printf("Enter the information part of the node");
scanf("%d",&new1-->info);
new1-->link=NULL;
if(start==NULL)
{
new1-->link=new1;
start=new1;
}
else
{
temp=start;
while(temp-->link!=start)
temp=temp-->link;
temp-->link=new1;
new1-->link=start;
}
}
}
C)Insertion at any position:
void insert_at_anypos()
{
//start,info and link are declared as global variable
struct node *new1, *temp;
int i,pos,c=0;
printf("Enter the position where the node is to be inserted");
scanf("%d",&pos);
temp=start;
do
{
c=c+1;
temp=temp-->link;
}while(temp!=start);
if(pos>c+1)
{
printf("Invalild position");
exit();
}
else
{
new1=(struct node *)malloc(sizeof(struct node));
if(new1==NULL)
{
printf("overflow");
exit();
}
else
{
printf("Enter the information part of the node");
scanf("%d",&new1-->info);
new1-->link=NULL;
if(pos==1)
{
if(start==NULL)
{
new1-->link=new1;
start=new1;
}
else
{
temp=start;
while(temp-->link!=start)
temp=temp-->link;
temp-->link=start;
start=new1;
}
}
else if(pos==c+1)
{
if(start==NULL)
{
new1-->link=new1;
start=new1;
}
else
{
temp=start;
while(temp-->link!=start)
temp=temp-->link;
temp-->link=new1;
new1-->link=start;
start=new1;
}
}
else
{
i=1;
temp=start;
while(i<pos-1)
{
temp=temp-->link;
i++;
}
new1-->link=temp-->link;
temp-->link=new1;
}
}
}
NOTE: codes for insertion at last position will be satisfied by codes for insertion before a given position as well as insertion after
a given position.

Deletion in single circular link list:


A)Deletion of first node:

C Program:
void delete_fnode()
{
//start, link are declared as a global variable
struct node *temp;
if(start== NULL)
{
printf(“undeflow”);
exit();
}
else if(start→link==start)
{
temp=start;
start→link=NULL;
start=NULL;
free(temp);
}
else
{
temp=start;
while(temp→link!=start)
{
temp=temp→link;
}
temp→link=start→link;
temp=start;
start=start→link;
temp→link=NULL;
free(temp);
}
}
B) Deletion of last node:
C Program:

void delete_lnode()
{
//start, link are declared as global variable.
struct node *temp, *prev;
if(start==NULL)
{
printf(“underflow”);
exit();
}
else if(start→link==start)
{
temp=start;
temp→link=NULL;
start=NULL;
free(temp);
}
else
{
for(temp=start, temp→link!=start;temp=temp→link)
prev→link=temp→link;
temp→link=NULL;
free(temp);
}
}

C)Deletion of node at any position


void delete_at_any_pos()
{
//start,link are declared as global variable.
int i,pos,c=0;
struct node *prev,*temp;
printf(“Enter the position of node which is to be deleted”);
scanf(“%d”,&pos);
if(start==NULL)
{
printf(“List has no node”);
exit();
}
else
{
temp=start;
do
{
c++;
temp=temp→link;
}while(temp!=start);
if(pos>c)
{
printf(“Invalid position”);
exit();
}
else if(pos==1)
{
if(start→link==start)
{
temp=start;
start=NULL;
temp→link=NULL;
free(temp);
}
else
{
temp=start;
while(temp→link!=start)
temp=temp→link;
temp→link=start→link;
temp=start;
start=temp→link;
temp->link=NULL;
free(temp);
}
}
else
{
for(i=1,temp=start;i<pos;i++,temp→link)
prev=temp;
prev→link=temp→link;
temp→link=NULL;
free(temp);
}
}

Searching:
void search()
{
// start, link and info are declared as global variable.
int item, c=0, nd_node=0;
struct node *temp;
printf(“Enter the item for searching”);
scanf(“%d”,&item);
if(start==NULL)
{
printf(“underflow”);
exit();
}
else
{
temp=start;
do
{
nd_node=nd_node+1;
if(temp→info==item)
{
c=c+1;
printf(“Item is found in node %d”,nd_node);
}
temp=temp→link;
}while(temp!=start);
if(c==0)
printf(“searching is unsuccessful”);
}
}

Sorting
C Program
void sort()
{
//start, link, info are declared as global variables.
int num;
struct node *temp1, *temp2;
for(temp1=start;temp→link!=start; temp1=temp1→link)
{
for(temp2=temp1→link; temp2!=start; temp2=temp2→link)
{
if(temp1→info>temp2→info)
{
num=temp1→info;
temp1→info= temp2→info;
temp2→info=num;
}
}
}
}
Concatenation in single circular link list
void concatenation()
{
//start1,start2, link, list1, list2, temp are global variables.
for(temp=start1;temp→link!=start1;temp=temp→link);
temp→link=start2;
for(temp=start1;temp→link!=start2;temp=temp→link);
temp→link=start1;
start2=NULL;
}

Double circular link list:


In a double circular link list, the next pointer field of last node points to the first node instead of containing NULL pointer and
previous pointer field of first node points to the last node instead of containing NULL pointer.

Representation of double circular link list: [refer class notes]


Condition for overflow:
if(new1==NULL) then overflow.

Condition for underflow:


if(start==NULL)then underflow.
single node condition:
if(start==start→next) or if(start→prev) then list contain a single node.

Traversing of double circular link list:


Traversing of double circular link list is the process of visiting each node in the list exactly once. Traversing in double
circular link list is classified into two types.
1)Forward display/traverse.
2)Backward display/traverse.
Forward display will display the information part of the list in forward manner i.e., from node1 to last node sequentially.
Backward display will display the information part of the list in forward manner i.e., from last to node1 node sequentially.

Forward Display:
C Program:
void display_forward()
{
//start,info,next are declared as global variable.
struct node *temp;
if(start==NULL)
{
printf(“List is empty”);
exit();
}
else
{
temp=start;
do
{
printf(“%d”,temp→info);
temp=temp→next;
}while(temp!=start);
}
}
Backward Display:
C Program:
void display_backward()
{
//start,info,next and prev are declared as global variable.
struct node *temp, *temp1;
if(start==NULL)
{
printf(“List is empty”);
exit();
}
else
{
temp=start;
while(temp→next!=start)
temp=temp→next;
temp1=temp;
do
{
printf(“%d”,temp→info);
temp=temp→next;
}while(temp!=start);
}
}
NOTE: In circular link list, the last node can be accessed directly if we have the address of 1 st node or the value of start. Also we
can access the 1st node if the address of last node is known.
HEADER LINKED LIST
Definition : Header link list is a link list where a special node 'HEAD' is there, which keep the information about the entire list.
This header node is the first node of the list. Start keeps the address of head node.
The information kept in the header node are:
1.How many nodes are there.
2.which type of list it is.
3.What type data are there in the list.

Types of hearder link list:


1. single header link list.
2.double header link list.
3.single header circular link list.
4.double header circular link list.

Declaration of head node:


struct node
{
int info;
struct node *link;
} *start;
struct head
{
int node_no;
char type[30];
char list_type[25];
struct node *link;
};

1) SINGLE HEADER LINK LIST:


The single link list containing head node as its first node is called single header list.
Condition for underflow:
if(start-->link==NULL)
then underflow or the list is empty.

Condition for single node:


if(start-->link-->link=NULL)then single node is there.

Note: To perform all the operation in single link list, change the underflow condition, single node checking condition and set
temp=start-->link in place of start.

Creation of single header link list


Algorithm:

PROCEDURE create_SHLL(new1,h,link,info,start,c,type,node_no,list_type)
Step 1: set c=0
Step 2: do
i) new1=allocate memory
ii)if(new1=NULL) then
a)print overflow
b)exit
iii) else
a)new1-->link=NULL
b)read new1-->info
new-->link=start
start=new1
c=c+1
Step 3: printf Enter your choice
i)creation
ii)stop
Step 4: While(ch!=0)
[end of step 2 do...while loop]
Step 5: h=allocate a memory.
Step 6:if(h=NULL ) then
i)print malloc can't allocate memory
ii)exit
Step 7: else
i)h-->type="integer"
ii)h-->node_no=c
iii)read h-->list_type
iv)h-->link=start
v)start=h
[end of step 6 if...else structure]
Step 8: Exit

C Program:

void Create_SHLL()
{
struct node *new1;
struct head *h;
int ch,c=0;
do
{
new1=(struct node *)malloc(sizeof(struct node));
if(new1==NULL)
{
printf("overflow");
exit();
}
else
{
new1-->link=NULL;
printf("Enter the information part:");
scanf("%d",&new1-->info);
new1-->link=start;
c=c+1;
}
printf("Enter your choice \n 1:creation\n 2.stop\n");
scanf("%d",&ch);
} while(ch!=0);
h=(struct head *)malloc(sizeof(struct head));
if(h==NULL)
{
printf("malloc cannot allocate memory for head node");
exit();
}
else
{
h-->type="integer";
h-->node_no=c;
printf("Enter the type of the list");
scanf("%s", &h-->list_type);
h-->link=start;
start=h;
}
}

Traversal of single header link list:Visiting all the elements in the list exactly once is called traverse.

Algorithm:
PROCEDURE Traverse(start,link,list,temp,info)
Step 1: if(start-->link=NULL) then
i)print the list is empty
ii)exit
Step 2: else
i)temp=start-->link.
ii)while temp!=NULL
a)print temp-->info
b)temp=temp-->link
[end of while]
[end of if...else loop]
Step 3:exit

C Program:
void traverse()
{
struct node *temp;
if(start-->link==NULL)
{
printf("list is empty");
exit();
}
else
{
for(temp=start-->link; temp!=NULL;temp=temp-->link)
printf("%d",temp-->info);
}
}

2) DOUBLE HEADER LINK LIST:The double link list containing head node as its first node is called double header list.
Representation of double header link list
Condition for underflow:
if(start-->next==NULL)
then underflow or the list is empty.

Condition for single node:


if(start-->next-->next=NULL)then single node is there.

Note: For traversal operation change the underflow condition and replace the temp=start by temp=start-->next

Traversal of double header link list:Visiting all the elements in the list exactly once is called traverse.

Forward traversal is same as that of single header link list.

Backward traversal:
Algorithm:
PROCEDURE Traverse_backward(start,prev,next,list,temp,info)
Step 1: if(start-->next=NULL) then
i)print the list is empty
ii)exit
Step 2: else
i)temp=start-->next.
ii)while temp-->next!=NULL
a) temp=temp-->next
[end of while]
iii)while (temp!=start)
a)print temp-->info
b)temp=temp-->prev
[end of while]
[end of if...else loop]
Step 3:exit

C Program
void traverse_backward()
{
if(start-->next==NULL)
{
printf("list is empty");
exit();
}
else
{
while (temp-->next!=NULL)
temp=temp-->next
while (temp!=start)
{
printf("%d",temp-->info);
temp=temp-->prev
}
}
}

3) SINGLE CIRCULAR HEADER LINK LIST:

The single header link list in which the last node points to the first node is called single circular header link list.
Representation of single circular header link list
Condition for underflow:
if(start-->link==start)
then underflow or the list is empty.

Condition for single node:


if(start-->link-->link=start)then single node is there.

Traversal of single header link list:Visiting all the elements in the list exactly once is called traverse.

Algorithm:
PROCEDURE Traverse(start,link,list,temp,info)
Step 1: if(start-->link=start) then
i)print the list is empty
ii)exit
Step 2: else
i)temp=start-->link.
ii)while( temp!=start)
a)print temp-->info
b)temp=temp-->link
[end of while]
c)print the address of 1st node i.e., start
[end of if...else loop]
Step 3:exit

C Program:
void traverse()
{
if(start-->link==start)
{
printf("list is empty");
exit();
}
else
{
for(temp=start-->link; temp!=start;temp=temp-->link)
printf("%d",temp-->info);
printf("%u",start);
}
}

4) DOUBLE HEADER CIRCULAR LINK LIST:


In double header link list, last nodes next part contain the address of head node and the previous part of the head node contain the
address of last node then it is called a double header circular link list.

Representation, Underflow condition, Single node condition. [Refer class notes]

Traverse:
Forward traverse
Algorithm:

Step 1: if(start-->next=start) then


a)print list is empty
b)exit
Step 2: else
a)for(temp=start-->next; temp!=start;temp=temp-->next)
print temp-->info
[end for]
Step 3: exit

C program

void forward_traverse()
{
if(start-->next==NULL)
{
printf("The list is empty");
exit();
}
else
{
for(temp=start-->next;temp!=start;temp-->next)
printf("%d",temp-->info);
}
}

Backward traverse
Algorithm:
Step 1: if(start-->next=start) then
a)print list is empty
b)exit
Step 2: else
a) temp=start-->next
b)while(temp-->next!=start)
temp=temp-->next
[end while]
c)while(temp!=start)
i)print temp-->info
ii)temp=temp-->prev
[end of while]
[end of if..else structure]
Step 3: exit

C program

void backward_traverse()
{
if(start-->next==start)
{
printf("The list is empty");
exit();
}
else
{
for(temp=start-->next;temp-->next!=start;temp-->next);
for(;temp!=start; temp=temp-->prev)
printf("%d",temp-->info);
}
}
LINKED STACKS

Implementation of stack using linked list:

Representation of stack by an array and by linked list: [Refer class notes]

Declaration of stack:
struct node
{
int info;
struct node *next;
};
struct node *top=NULL;

Note:
1. The terminology we used here is top in place of head.
2.Any element we want to push into stack must be inserted as first node, as top is the list pointer variable.
3.Top should hold the address of the node that we want to insert.
Push:Push operation is exactly similar to insertion of a node at first position.

Algorithm:

PROCEDURE PUSH(top,info,next,list,new1)

Step 1: Create a node nad store its address in "new1".


Step 2: [check for overflow]
if(new1==NULL)
a.print overflow
b.exit
[End if]
Step 3: Read info
Step 4: set new1-->next=NULL.
Step 5:[insertion of node into list]
a. set new1-->next=top.
b.top=new1.
Step 6: Exit.

C-Program:
void push()
{
struct node *new1;
new1=(struct node *)malloc(sizeof(struct node));
if(new1==NULL)
{ printf("overflow");
exit();
}
else
{
printf("Enter the information part:");
scanf("%d",&new1-->info);
new1-->next=NULL;
new1-->next=top;
top=new1;
}
}

Pop: we can pop the node whose address is holded by list pointer variable top. So, as top holds the address of 1st node. We can
delete 1st node which has been inserted lastly.

Algorithm:
PROCEDURE POP(top,next,temp)
Step 1: set temp=NULL
Step 2: [check for underflow]
if(top==NULL)
a.print underflow
b.exit
Step 3: [single node]
else if(top->next==NULL)
a.temp=top
b.top=NULL
c.free the temp.
Step 4: else
a.temp=top
b.top=temp-->next
c.temp-->next=NULL
d.free the temp using free() function
Step 5: Exit

C-Program:

void pop()
{
temp=NULL;
if(temp==NULL)
{ printf("underflow");
exit();
}
else if(top-->next=='\0')
{ temp=top;
top=NULL;
free(temp);
}
else
{
temp=top;
top=temp-->next;
temp-->next=NULL;
free(temp);
}
}

Display:

Algorithm:
Step 1: set temp=NULL.
Step 2: [check for underflow]
if(top==NULL)
a.print the list is empty
b.exit
Step 3:else
for(temp=top; temp!=NULL; temp=temp-->next)
a.print(temp-->next)
b.prnit NULL
Step 4:exit

C-Program:

void display()
{
temp=NULL;
if(top==NULL)
{ printf("list is empty");
exit();
}
else
{ for(temp=top;temp!=NULL;temp=temp-->link)
printf("%d-->",temp-->info);
printf("NULL");
}
}

A program to implement stack using singly linked list

#include<stdio.h>
#include<stdlib.h>
struct node
{
int info;
struct node *next;
} *top=NULL,*temp;

void main()
{
int ch;
printf(“\n 1. PUSH \n 2.POP\n 3.DISPLAY \n 4.EXIT”);
while(1)
{
printf(“Enter the choice:”);
scanf(“%d”,&ch);
switch(ch)
{
case 1: push();
break;
case 2: pop();
break;
case 3: display();
break;
case 4: exit(0);
}
}
}

Note: Attach push(), pop(), display() function.


LINKED QUEUE
Implementation of queue by linked list

Array Representation AND Linked list Representation: [Refer class notes]

Declaration:
struct node
{
int info;
struct node *next;
} *front=NULL,*rear=NULL;

NOTE:
1) In linked list representation of queue, front acts as the list pointer variable and holds the address of node that is first inserted.
2) Rear is the pointer variable which holds the address of node which has been inserted at last.
3)Here we can insert node/element after last node.
4)We can delete the node whose address is holed by front that is the first node.
Algorithm:

PROCEDURE Insert_Q(next,info,front,rear,new1)

Step 1: [check for overflow]


if new1==NULL then
a. printf overflow
b. exit
Step 2:else
a. read new1-->info
b. set new1-->next!=NULL
Step 3: [Check for underflow]
if(rear=NULL)
a. set front=new1
b.set rear=new1
Step 4: else
a. set rear-->next=new1
b.set rear=new1
[End of step 2 if structure]
[End of step 1 if structure]
Step 5:exit

C Program

void Qinsert()
{
new1=(struct node *)malloc(sizeof(struct node));
if(new1==NULL)
{
printf("overflow");
exit();
}
else
{
printf("Enter the information part:");
scanf("%d",&new1-->info);
new1-->next=NULL;
if(rear==NULL)
{
front=new1;
rear=new1;
}
else
{
rear-->next=new1;
rear=new1;
}
}
}

Deletion:
Algorithm:

PROCEDURE Delete_Q(next,info,front,rear)

Step 1: [check for underflow]


if(front==NULL)
a.print underflow
b.exit
Step 2:
else
if(front-->next=NULL)
temp=front
free temp
front=NULL
rear=NULL
[End of if structure]
Step 3: [check for more than one node]
else
a.temp=front
b.front=temp-->next
c.temp-->next=NULL
d.free temp
Step 4: Exit

C-Program:

void delete_Q()
{ struct node *temp;
if(front==NULL)
{ printf("underflow");
exit();
}
else if(front-->next==NULL)
{ temp=front;
free(temp);
front=NULL;
rear=NULL;
}
else
{
temp=front;
front=temp-->next;
temp-->next=NULL;
free(temp);
}
}

Display:
Algorithm:
Step 1: set temp=NULL.
Step 2: [check for underflow]
if(front==NULL)
a.print the list is empty
b.exit
Step 3:else
for(temp=front; temp!=NULL; temp=temp-->next)
a.print(temp-->next)
b.prnit NULL
Step 4:exit

C-Program:

void display_Q()
{
temp=NULL;
if(front==NULL)
{ printf("list is empty");
exit();
}
else
{ for(temp=front;temp!=NULL;temp=temp-->link)
printf("%d-->",temp-->info);
printf("NULL");
}
}

A program to implement queue using singly linked list

#include<stdio.h>
#include<stdlib.h>
struct node
{
int info;
struct node *next;
} *front=NULL,*rear=NULL,*temp;

void main()
{
int ch;
printf(“\n 1. INSERT \n 2.DELETE\n 3.DISPLAY \n 4.EXIT”);
while(1)
{
printf(“Enter the choice:”);
scanf(“%d”,&ch);
switch(ch)
{
case 1: insert_Q();
break;
case 2: delete_Q();
break;
case 3: display_Q();
break;
case 4: exit(0);
}
}
}

Note: Attach insert_Q(), delete_Q(), display_Q() function.

APPLICATIONS OF LINKED LIST:


Various applications of linked list are:
1)Representation of polynomial and performing various operations such as addition, multiplication and evaluation on it.
2)Performing addition of long positive integers.
3)Representing non-integer and non-homogeneous list.

Advantages of linked representation over arrays:


1) Only one pointer will be needed to point to first term of the polynomial.
2) No prior estimation on number of terms in the polynomial is required. This results in flexible and more space efficient
representation.
3) The insertion and deletion operations can be carried out very easily without movement of data.

Disadvantage of linked representation over arrays:


1)We cannot access any term randomly or directly we have to go from start(head) node always.

POLYNOMIALS
Polynomial Representation Through Link List
A polynomial is an expression that contains more than two terms. A term is made up of coefficient and exponent. An example of
polynomial is
P(x) = 4x3+6x2+7x+9

A polynomial thus may be represented using arrays or linked lists. Array representation assumes that the exponents of the given
expression are arranged from 0 to the highest value (degree), which is represented by the subscript of the array beginning with 0.
The coefficients of the respective exponent are placed at an appropriate index in the array. The array representation for the above
polynomial expression is given below:

A polynomial may also be represented using a linked list. A structure may be defined such that it contains two parts- one is the
coefficient and second is the corresponding exponent.

Polynomial having one variable:

Thus the above polynomial may be represented using linked list as shown below:

The structure definition may be given as shown below:

struct node
{
int coeff;
int expo;
struct node *link;
};

Polynomial having more than one variable:

Let the polynomial is:

5x3y2+6x2y2+7x-6y+15
Note:

1) Total no. of nodes in the list == Total no. of terms in the polynomial.
2) If total number of variables in the polynomial = n , then each node will have n+2 parts.

Addition of two Polynomials:

For adding two polynomials using arrays is straightforward method, since both the arrays may be added up element wise
beginning from 0 to n-1, resulting in addition of two polynomials. Addition of two polynomials using linked list requires
comparing the exponents, and wherever the exponents are found to be same, the coefficients are added up. For terms with
different exponents, the complete term is simply added to the result thereby making it a part of addition result. The complete
program to add two polynomials is given in subsequent section.

[For program refer lab program: 9]

SPARSE MATRIX REPRESENTATION


A sparse matrix is a kind of matrix which has a very few non zero elements, as compared to the size m*n of the matrix.
For example: If the matrix is of size 100*100 and only 10 elements are non zero. The concept of sparse matrix has came forward
in computer science to investigate such a representation which will store only non-zero elements of the matrix and still carry out
the operations quite efficiently.

Representation of Sparse Matrix:


[Refer class notes]

Program to create and display linked representation of sparse matrix:

#include<stdio.h>
#include<stdlib.h>
#include<conio.h>

struct sparse
{
int row;
int col;
int val;
struct sparse *next;
} *head=NULL;

struct sparse *create(struct sparse *, int, int, int);


void display(struct sparse *);

struct sparse *create(sgtruct sparse *new, int r, int c, int val)


{
struct sparse *temp;
if(new==NULL)
{
new=(struct sparse *new)malloc(sizeof(struct sparse));
if(new==NULL)
{
printf(“error\n”);
exit(0);
}
new→row=r;
new→col=c;
new→val=val;
new→next=NULL;
}
else
{
temp=new;
while(temp→next!=NULL)
temp=temp→next;
temp→next=(struct sparse *)malloc(sizeof(struct sparse));
if(temp→next==NULL)
{
printf(“error\n”);
exit(0);
}
temp=temp→next;
temp→row=r;
temp→col=c;
temp→val=val;
temp→next=NULL;
}
return(new);
}

void display(struct sparse *temp)


{
while(temp!=NULL)
{
printf(“%d %d %d\n”,temp→row, temp→col, temp→val);
temp=temp→next
}
}

void main()
{
int r,n,c,val;
clrscr();
struct sparse *head=NULL;
printf(“\n Enter the number of non-zero terms in the sparse matrix\n”);
scanf(“%d”,&n);
while(n>0)
{
printf(“Enter the row number, column number, and value\n”);
scanf(“%d%d%d”, &r,&c,&val);
head=create(head,r,c,val);
n--;
}
printf(“The linked sparse matrix is\n”);
display(head);
getch();
}
Questions
1)Write the following algorithm for singly linked list. (Jan-19,10M)
i)Inserting ITEM as the first node in the list.
ii)Deleting the node with the given ITEM of information.
iii)To insert a node at the specified position.(Jul-08,6M)

2)Write the node structure for linked representation of polynomial. Write the function to add two polynomials
represented using linked list (Jan-19,10M)
3)Write the functions to perform the following: (Jan-19,10M)
i)Inverting a singly linked list.
ii)Concatenating the singly linked list.
iii)Finding the length of a circular list.
4) Write a note on header linked list .Explain the widely used header lists with diagrams(Jan-19,5M)(Jul-18,5M)
5) For the given sparse matrix, write the diagrammatic linked list representation.( Jan-19,5M)
2 0 0 0
4 0 0 3
0 0 0 0
8 0 0 1
0 0 6 0

6) Write a function(Jul-11,12M)
i)to find GCD of two number.
ii)to find factorial of a number.
iii)to reverse positive integer number.
iv) to search an element in the list that is unsorted and a list that is sorted.
7)Enlist the advantages and disadvantages of Doubly Linked List(DLL) over Single Linked List(SLL). (Jul-11,8M)
8)Write a function to insert and delete a node, in Doubly Linked List, with respect to given position. (Jul-11,10M)
9) What is dynamic memory allocation? Write a function to delete a node from a circular linked list. Proper error
message should be displayed. (Jul-11,10M)
10)Write the following functions for singly linked list: (Jan-18, 8M)
(i) Reverse the list (ii) Concatenate two lists. (Jan-10, 5M)
11)Write function insert_front and delete_front using doubly linked list. (Jan-18, 8M) (Dec-10,10M)
12)Write an algorithm to add two polynomials. (Jan-18,8M)
13)Define sparse matrix. Give sparse matrix representation of linked list for given matrix. (Jan-18, 8M)
A= 0 0 4 0 0
6 5 0 0 0
0 3 0 1 0
0 0 0 0 2

14)Briefly explain the structures of different types of linked lists. Write a C function to count number of elements
present in a singly linked list. (Dec-10,12M)
15)How can an ordinary queue be represented, using a singly linked list? Write C functions for linked implementation
of ordinary queue insertion and deletion. (Dec-10, 10M)(Jul-08,10M)
16) What is a linear linked list? Write the algorithm to add an element to the front of the list. (Jun-10,5M)
17) What are the advantages and disadvantages of representing a group of items as an array versus linear list?
(Jun-10,5M) (Jan-09,4M)
18) Write the following C routines for the dynamic implementation of a linked list. NODEPTR is of type pointer to a
node. (Jun-10,10M)
i) void insertafter(NODEPTR p, int x) which insert a node with information x after a node pointed to by p.
ii) void place(NODEPTR *plist, int x) which insert a node with information x at a proper position within the
linear linked list pointed to by *plist. The list is assumed to contain information in the increasing order. (Jun-10,10M)

19)What is a circular list? Explain with a diagram. (Jun-10,5M)

20) Compare linear linked list and doubly linked list, with diagrams. (Jun-10,5M)(Jul-09,4M)
21) Give the C implementation of stack as circular list. (Jun-10,10M)
22)Explain how the linked list can be represented using arrays(Jan-09,4M)
23)Write a C function to merge two ordered linked list.(Jan-09,6M)
24)Write a C program to perform the operation on stack using singly linked list(Jan-09,10M)(Jan-10,10M)
25)Explain the following: i) circular list ii) doubly linked list. Using suitable diagrams.(Jan-09,6M)
26)Write a C routine to perform following operations using circular linked list.(Jan-09,10M)
i)To place the elements of a list in increasing order.
ii)To find the sum of integers and the number of elements in a list.
27)What are the advantages and disadvantages of representing a stack or queue by a linked list?(Jan-10,4M)
28)Write a note on noninteger and nonhomogeneous list.(Jan-10,6M)
29) Explain with figure circular list with a header node.(Jan-10,5M)
30) Assume that first and last are external pointers to the first and last nodes of a doubly linked list. Write an algorithm
to implement the following: (Jan-10,10M)
i)Insert a node to the list at the front end.
ii)Delete a node from the front end.
31) What is linked list? With a neat diagram show how an element is added and removed from the front end of the
list.(Jul-09,10M)
32) What is a Header node? Give example with neat diagram.(Jul-09,4M)
33)Write a C function insend(plist,x) to insert the element ‘x’ at the end of the list ‘list’. (Jul-09,6M)
34) Write a program to insert a given value into an ordered doubly linked list into its proper position. (Jul-09,6M)
35) Write a C program to perform following operation (jul-09, 10M)
i) Create a list adding nodes at front.
ii)Delete a node at given position.
36) List out any two applications of linked list and any two advantages of doubly linked list over singly linked list
(Jul-08, 4M)
37) Write a C program to perform the following operations on a doubly linked list(Jul-08, 10M)
i) To create the list by adding each node at the front.
ii) To display all the elements in reverse order.
38) Write a C program to create a linked list and interchange the element to the list at position m and n and display
contents of the list before and after interchanging the elements.(Jul-08, 10M)
39)Give the node structure to create a linked list of integers and write C function to perform the following:
(Jul-17,10M)
i) Create a three node list with data 10,20 and 30.
ii) Insert a node with the data value 15 in between the nodes having the data values 10 and 20.
iii) Delete the node whose data is 20.
iv) Display the resulting singly linked list.

40)Write a node structure for linked representation of polynomial. Explain the algorithm to add two polynomials
represented using linked list. (Jul-17,6M)
41)Write C function to perform the following: (Jul-17,6M)
i) Reversing a singly linked list.
ii) Concatenating singly linked list.
iii) Finding the length of the list.

42) List out the difference between the doubly linked list and singly linked list. Illustrate with example the following
operations on a doubly linked list: (Jul-17,10M)
i) Inserting a node the beginning
ii) Inserting at the intermediate position.
iii) Deletion of a node with a given value.
iv) Search a key element.

43) Given an ordered linked list whose first node is denoted by ‘START’ and node is represented by ‘key’ as
information and ‘link’ as link field. Write a C program to implement deleting number of nodes (consecutive) whose
‘key’ values are greater than or equal to ‘kmin ’ and less than ‘kmax’ (Jan-08,12M)
44) Write a C program to implement the insert and delete operation on queue using linked list. (Jan-15, 10M)
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner

You might also like