Skip to main content

Posts

Showing posts from December, 2021

Delete duplicate-value nodes from a sorted linked list-Hackerrank Solution

Problem You are given the pointer to the head node of a sorted linked list, where the data in the nodes is in ascending order. Delete nodes and return a sorted list with each distinct value in the original list. The given head pointer may be null indicating that the list is empty. Solution: /*  * Complete the 'removeDuplicates' function below.  *  * The function is expected to return an INTEGER_SINGLY_LINKED_LIST.  * The function accepts INTEGER_SINGLY_LINKED_LIST llist as parameter.  */ /*  * For your reference:  *  * SinglyLinkedListNode {  *     int data;  *     SinglyLinkedListNode* next;  * };  *  */ SinglyLinkedListNode* removeDuplicates(SinglyLinkedListNode* llist) {          SinglyLinkedListNode* temp=llist;     SinglyLinkedListNode* tem=llist;     SinglyLinkedListNode* del=llist;     while (temp->next!=NULL) {         if(temp->data==temp->next->data)         {             del=temp->next;             temp->next=del->next;             delete del;    

20 Easy Ways to Make Money in India - No Investment Necessary

 INTRODUCTION Did the idea of ​​sitting at home come to your mind? Tired of finding an easy way to make money without investing in India? Especially  when the economy is at its worst, opportunities to work from home  are increasing. There are many jobs online  that you can get if you study hard. There are many easy ways to make money in India, which requires minimal skills. Searching the internet for ways to make extra income in India will educate you on the different ways to achieve it. Everyone else is looking for the best and easiest way to make money online in India. But no one wants to learn the process needed to get there. In this article, we will explain the best and easiest way to make money in India, along with the processes to remember and the tips you need. Various suspicious, non-genuine methods are pervasive throughout the Internet and you can't go anywhere. We recommend that you do not fall into the trap of guaranteeing a lot of money in a very short time. Always look