Friday 14 October 2016

Write a program to find smallest and highest number from an array?

Q1. : Write a program to find smallest and highest number from an array?

/*    ##################################
            Girfa : Student Help
            Program : Count Highest/smallest
            For more program visit : http://girfahelp.blogspot.in/2012/09/some-program-of-c-language.html
      ###################################
      */
#include<stdio.h>
#include<conio.h>
void main()
{
      int ar[5],i,small=0,big=0;
      clrscr();
      for(i=0;i<5;i++)

Flow Chart



Flow Chart

 Flow chart a diagram is use to graphically represent program logic, algorithm and workflow model because A picture is worth a thousand words. Flow chart is easy way to write down programming logic using various symbols which help programming easily convert these symbols of logic into its equivalent code in any language. Flow chart decreases software development process.


The first structured method for document process flow, the "flow process chart", was introduced by Frank and Lillian Gilbreth to members of the American Society of Mechanical Engineers (ASME) in 1921 in the presentation "Process Charts: First Steps in Finding the One Best Way to do Work". The Gilbreths' tools quickly found their way into industrial engineering curricula. In the early 1930s, an industrial engineer, Allan H. Mogensen began training business people in the use of some of the tools of industrial engineering at his Work Simplification Conferences in Lake Placid, New York.

Practice Question Data and Variable C language

Q1. What is difference between sign and unsigned data type in C language?

 Q2. What is difference between float and double data type?

 Q3. What do you understand by garbage data?

 Q4. If a variable is used in any expression without initialization then what will be result?

 Q5. What the use of scientific notation?

Thursday 13 October 2016

Microsoft Excel Rate Depreciation List for Car Sale

Prepare a worksheet for the following problem:

You are looking to buy a car. You are considering two options: to buy a second hand car and keep it for ten years or to buy a new car and keep it for four years. The depreciation per year is simply the difference between the purchase price and the resale price divided by the numbers of years. The total running cost per year is the sum of service/repair cost, the fuel cost per year (miles per year multiplied by fuel cost per mile) , the tax and the insurance. The total cost per year is the sum of the depreciation and the running costs. You are supposed to calculate average depreciation per year, fuel cost per year, total running cost per year and total cost per year for both the options. Type in labels: car purchase option, initial cost, resale, years ,average depreciation per year, running cost, services/repairs per year, miles per year, fuel cost per mile, fuel cost per year, tax, insurance, total running cost and total cost per year. Prepare the worksheet having all the details as given below:

Wednesday 12 October 2016

July, 2015 A8-R4: BASICS OF OS, UNIX & SHELL PROGRAMMING

July, 2015
A8-R4: BASICS OF OS, UNIX & SHELL PROGRAMMING

PART ONE
(Answer all the questions)

1. Each question below gives a multiple choice of answers. Choose the most appropriate one and enter in the “OMR” answer sheet supplied with the question paper, following instructions therein. (1x10)
1.1 The fast and expensive storage device
A) Register
B) Electronic disk
C) Magnetic disk
D) Optical disk
1.2 Which command is used to change protection mode of files starting with the string emp and
ending with 1,2, or 3?
A) chmod u+x emp[1-3]
B) chmod 777 emp*
C) chmod u+r ??? emp
D) chmod 222 emp?

Variable Input Output C Language

c-language-variable-input-o

As you have in previous chapter what is a variable now I am going to demonstrate that how to declare and read/write into a variable.
Declaration syntax

Declare single variable

Data_type Variable_name;

Declare more than one variable

Data_type Var_name1,var_name2…var_nameN

Declare and initialize

Data_type var_name1=val1,var_name2=val2…var_nameN=valM

Variable Declaration

When you make a variable. It’s known as declaration in terms of C language. Declaration request OS for claiming space on physical memory.

Initialization

First value assign to a variable after declaration. What if you didn’t initialize a variable then an unpredicted value assigned which is known as garbage so initialization   is mandatory for denied facing socking result.

Monday 10 October 2016

January, 2016 A8-R4: BASICS OF OS, UNIX & SHELL PROGRAMMING

January, 2016
A8-R4: BASICS OF OS, UNIX & SHELL PROGRAMMING

PART ONE
(Answer all the questions)

1. Each question below gives a multiple choice of answers. Choose the most appropriate one and enter in the “OMR” answer sheet supplied with the question paper, following instructions therein. (1x10)
1.1 What does the following command do?
who | wc –l
A) List the number of users logged in
B) List the users
C) List the number of users in the system
D) Display the content of who command
1.2 What is the default number of files open per user process?
A) 0
B) 1
C) 2
D) 3
1.3 $ oneko &

Sunday 9 October 2016

NIELIT Assignment 12 : Basics of Os, Unix and Shell Programming

Assignment 12

a) Write a command to change modification time of a file without modifying the
file.

b) Write a command to display name of a file in your current directory whose
size is maximum.

NIELIT Assignment 11 : Basics of Os, Unix and Shell Programming

Assignment 11.

a) Write a command to convert contents of a file a.txt to upper case

b) Write sequence of commands to convert 1st line of a file a.txt to upper case

NIELIT Assignment 10 : Basics of Os, Unix and Shell Programming

Assignment 10.

Using vi editor

a) Write a command to undo last action.

b) Write a command to create abbreviation LU as Linux Unix.

NIELIT Assignment 10 : Basics of Os, Unix and Shell Programming

Assignment 10.

Using vi editor

a) Write a command to undo last action.

b) Write a command to create abbreviation LU as Linux Unix.

NIELIT Assignment 9 : Basics of Os, Unix and Shell Programming

Assignment 9.

Using vi editor
a) Write a command to copy line number 1,10 after line number 25.

b) Write a command to move line number 1,10 after line number 25.

NIELIT Assignment 8 : Basics of Os, Unix and Shell Programming

Assignment 8.

Using vi editor write commands to do the following
a) Combine five lines into a single line.

b) Search a pattern printf and then repeat the search in opposite direction.

NIELIT Assignment 7 : Basics of Os, Unix and Shell Programming

Assignment 7.

a) Use chmod –w . and then try to create and remove a file in the current
directory. What is its output.

b) Run the commands (i) ls –ld . and (ii) ls –l .. Explain its output.

NIELIT Assignment 6 : Basics of Os, Unix and Shell Programming

Assignment 6.

a) Write a command to compare two text files.

b) Write a command to copy a file with permission 444.Copy it again and explain
your observation.

NIELIT Assignment 5 : Basics of Os, Unix and Shell Programming

Assignment 5.

a) How does the command mv bar1 bar2 behave , where both bar1 and bar2 are directories, when (i) bar2 exists and (ii)bar2 does not exist

b) Write a command to display lines common to a.txt and b.txt?

c) Write a command to display lines unique to a.txt?

NIELIT Assignment 4 : Basics of Os, Unix and Shell Programming


Assignment 4.

a) Run the following command and explain its output
(i) cd ../.. (ii)mkdir ../bin (iii)rmdir .. (iv)ls ..

b) Write a command to remove entire directory structure
DOEACC/ALEVEL/AL55 in one command?

NIELIT Assignment 3 : Basics of Os, Unix and Shell Programming

Assignment 3.

a) Convert the decimal number 192 to octal and hexadecimal using bc command.

b) Run ps , the script command and run ps again . What is its output. Explain

NIELIT Assignment 2 : Basics of Os, Unix and Shell Programming

Assignment 2.

a) Explore the filesystem tree using cd, ls, pwd and cat. Look in /bin, /usr/bin, /sbin, /tmp and /boot. What do you see?.

b) Explore /dev. Can you identify what devices are available? Which are character-oriented and which are block-oriented? Can you identify your tty (terminal) device (typing who am i might help); who is the owner of your tty

NIELIT Assignment 1: Basics of Os, Unix and Shell Programming

Assignment 1.

Try the following command sequence and write its output:
cd ; pwd ;ls -al ; cd . ;pwd (where did that get you?) ; cd .. ;pwd ; ls -al ; cd .. ; pwd;ls -al ;cd