Posts

Showing posts from February, 2016

Stack Program Using C++

************** Stack Program Using C++******************* ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// Program Name :- MyStack.cpp Description :- This program illustrate the concept of stack in C++. Object Oriented Implementation of stack. ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #include<iostream> using namespace std; typedef int BOOL; #define TRUE 1 #define FALSE 0 // // Declaration of class stack // class Stack {         //         // Class Member         //         private:                     int top;                     int MAX;                     int *arr;        public :                    Stack();                   // Default Constructor.                   Stack(int);               // Parameterize

Kernel Module Basic Programs

*******************  Kernel Module Basic Programs************************************ ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// Program Name :- Module1.c Description :- This program illustrate the concept of first kernel module program. //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #include<linux/module.h> #include<linux/kernel.h> int init_module(void) { printk(KERN_INFO "Jay shreeKrishna\n"); return 0; } void cleanup_module(void) { printk(KERN_INFO "Hare Ram\n"); } ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// File Name :- Makefile ///////////////////////////////////////////////////////////////////////////////////////

Introduction to Watch Command In Linux

Image
*********Introduction to Watch Command In Linux*********** Watch is Linux command that allows you to execute command or program periodically also shown your output on screen.This means that we shown your command output time to time. By default watch re-execute command or program every 2 seconds.The time can  be easily change our requirement. Watch is  extremely easy to use in terminal of Linux. We have to just open a terminal and type below command                                       watch free -m  The above command will check your system free memory and update result of free commands for every two seconds. How to change periodical time we have to just use  -n option , that specifies the interval with which the command will be executed. This interval is specifies in seconds.  We have to run script.sh file in every 10 seconds, we have to specify following command.                               watch -n 10 script.sh Note that, we have to run this above command, we

Step to Set Path For Java Program In Windows

Image
*************** Step to Set Path For Java Program In Windows **************************** Step 1 : Before we have to set path from your computer, check whether path is already set or not. Open Command Prompt and type javac and java. We have to occur any error then not set a path. Step 2 : Download and Install jdk from oracle site. Step 3 : Go to My Computer and Open Folder " C:\Program Files\Java\jdk1.7.0_10\bin " and copy that path. Step 4 : We have to Right click on MyComputer->properties->Advance System Security-> Environment Variable->New. We have to set application variable path, variable name and variable value is paste a copy in that text box and press OK. Step 5 : We have also set System Path, select path variable in that below list and edit that variable. Do not delete all path in that variable. We have to edit that press semicolon and close previous path and paste your java path. click Ok. Step 6 : We h