Untitled Document
Getting Started !!
1. Program - To Print sum of two numbers Click Here
       #!/bin/ksh 
       #********* Source Code From Website - Mangadaku - visit us at -http://mangadaku.com/ *****      
       # Program To Print sum of two numbers
       
       #We have hardcode variables x and y 
       
       x=10
       y=15
       sum=`expr x + y`
       echo " Sum of $x and $y is : $sum "
       
2. Program - To Read Input Provided By User Click Here
       #!/bin/ksh 
       #********* Source Code From Website - Mangadaku - visit us at -http://mangadaku.com/ *****      
       # Program - To Read Input Provided By User
       
       echo " Enter any string,character,number !!! "
       read uservalue
       echo " You have entered : $uservalue "
       
3. Program - To Convert and print distance in meters , feet , inches and centimeters Click Here
       #!/bin/ksh 
       #********* Source Code From Website - Mangadaku - visit us at -http://mangadaku.com/ *****      
       # Program - To Convert Distance entered in KM to Meters,Centimeters,inch,feet 
       
       echo " Please enter the Distance in Kilometers  !!! "
       read km
       
       let meters=$km*1000;
       echo " Distance in Meters : $meters "
       
       let cm=$km*100000;
       echo " Distance in Centimeters : $cm "
       
       let inch=$km*39370.1;
       echo " Distance in Inches : $inch "
       
       let feet=$km*39370.1;
       echo " Distance in Feets : $feet "
       
4. Program - To calculate area of Triangle Click Here
       #!/bin/ksh 
       #********* Source Code From Website - Mangadaku - visit us at -http://mangadaku.com/ *****      
       # Program - To Print Area of Triangle 
       
       echo " Enter Height of a triangle "
       read height
       
       echo " Enter Base of triangle "
       read base
       
       let area="( $height * $base ) * 0.5 "
       echo " Area Of triangle is : $area "
       
       
5. Program - To Display  current date, time, username, and current directory Click Here
       #!/bin/ksh 
       #********* Source Code From Website - Mangadaku - visit us at -http://mangadaku.com/ *****      
       # Program - To Display current date, time, username, and current directory 
       
       echo " Hello ` who am i ` "
              
       echo " You are logged in to Host `hostname` "
              
       echo " Today's Date is : `date` "
       
       echo " Your Present Working Directory is : `pwd` "
       
       
Untitled Document