Programming

Simplest C++ Code to Reverse the linked list

This is the simplest and easiest program to understand how to reverse the linked list. I have used same function to create a linkedlist and to reverse the linkedlist. Comments and suggestions are welcome. input 1 -> 2 -> 3 -> 4 -> 5 output 5 -> 4 -> 3 -> 2 -> 1 #include(…)

Read More

C++ Program to Find Intersection of Two Link-list.

Given two lists sorted in increasing order, create and return a new list representing the intersection of the two lists. The new list should be made with its own memory — the original lists should not be changed. For example, let the first linked list be 1->2->3->4->6 and second linked list be 2->4->6->8, then your(…)

Read More

Simple Parser Written in Python(Simple Crawler)

This is a simple code which shows you how parser works. This program will ask user for a keyword and depth in integer. it will go to google search for the entered keyword and crawl the site, put the links in a text file. After that keep crawling the links till the depth. This program(…)

Read More

Java Programing – Declaring and Initializing Variables

Java supports different variables to store data in memory. There are two major types of variable in java, known as primitives and complex objects. Primitives variables are stored in fast as possible in the memory. They are numeric values, single character and boolean values everything else we use to store in memory in java application(…)

Read More

Java Program – Passing an Argument to the Application

When we create a main class in Java, it always has a main method which startups when an application begins. The syntax of main method looks like following: public static void main(String[] args) It has the keyword “public” “static” and “void”. Public means that the method can be called from anywhere, Static means that we(…)

Read More