simplylearntopics
8 followers -
Only about c,c++,java,stack,hash,q,tree,graphs and all logical interview questions
Only about c,c++,java,stack,hash,q,tree,graphs and all logical interview questions

8 followers
Posts
Post has attachment

If we pass head pointer to Delete Method,it should delete the complete linkedlist.Here Main Logic lies as below Steps

Step 1: Store Head element into current element

Step 2: Point “next Element” of current element to “next Pointer”

Step 3: delete current element

Step 4: store next pointer to current element

Step 5: move next to next element

Step 6: Loop through,untill we found next element as NULL
Post has attachment

Rotate the linked list by "k"th element's in clockwise in a given linked list. let's go by few examples

Example 1:

Input:- 10->20->30->40->50->60 and input k = 4

Output:- 50->60->10->20->30->40

Example 2:

Input:- 10->20->30->40->50->60 and input k = 3

Output:- 40->50->60->10->20->30
Post has attachment

Each node will point to next node in the loop.it can form loop if it makes pointing to same node previously.Let’s go by some example.

Problem can be solved by using the below technique:

We have to take two pointers say ( slow Pointer ) and fast pointer ( 2 times of slow pointer ).first we will find out the loop by moving the slow pointer from head by one and head pointer move by 2 times of lenth.They will meet at the one point.if they meet we call there is a loop.

Each node will point to next node in the loop.it can form loop if it makes pointing to same node previously.Let’s go by some example.

Problem can be solved by using the below technique:

We have to take two pointers say ( slow Pointer ) and fast pointer ( 2 times of slow pointer ).first we will find out the loop by moving the slow pointer from head by one and head pointer move by 2 times of lenth.They will meet at the one point.if they meet we call there is a loop.

Post has attachment

By word Rsync means remote sync.Rsync command is used to sync two folders locally or remotely across hosts.Rsync has upper hand compared to “scp” command because it uses encryption and decryption while sending and receiving.rsync not only copies data ,it also copies links, devices, owners, groups and permissions from source to the target.
Post has attachment
http://simplylearntopics.com/20-linux-sed-command-examples/

Linux Sed is stream(buffer) editor.It means it receives data from stdin and process the data and output it to Desktop or some file.Sed process the data in pipe.So,we dont need to give input from file.Any intermediate output can be given to sed pipe command.
http://simplylearntopics.com/20-linux-sed-command-examples/

Linux Sed is stream(buffer) editor.It means it receives data from stdin and process the data and output it to Desktop or some file.Sed process the data in pipe.So,we dont need to give input from file.Any intermediate output can be given to sed pipe command.