model foc manual
TRANSCRIPT
-
8/3/2019 Model FOC MAnual
1/43
MOHAMED SATHAK A.J COLLEGE OF ENGINEERING,OMR, EGATTUR CHENNAI-603 103
DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING, YEAR - III, SEMESTER- V
CLASS ADVISOR: Mrs. G.Jayanthi TIME TABLE HOD : Mrs.G.Jayanthi
TIME8.30-9.15
9.15-10.00
10.00-10.45
BRE
AK
11.00-11.45
11.45-12.30
LUNCHB
REAK
1.15-2.00
2.00-2.45
2.45-3.30
DAY 1 2 3 4 5 6 7 8
MON Computer practicelab I
TUES Computer practice lab I
WED
THUR
FRI
SUBJECTCODE
COURSE TITLE FACULTY NAME
GE2115 Computer practice lab I Mr.Radha krishnan
HOD/CSE PRINCIPAL
-
8/3/2019 Model FOC MAnual
2/43
COMPUTER PRACTICE LABORATORY
LIST OF EXERCISES
a) Word Processing
1. Document creation, Text manipulation with Scientific notations.
2. Table creation, Table formatting and Conversion.
3. Mail merge and Letter preparation.
4. Drawing - flow Chart
b) Spread Sheet
5. Chart - Line, XY, Bar and Pie.
6. Formula - formula editor.
7. Spread sheet - inclusion of object, Picture and graphics, protecting the
Document and sheet.
8. Sorting and Import / Export features.
Simple C Programming
9. Data types, Expression Evaluation, Condition Statements.
10. Arrays
11. Structures and Unions
12. Functions
-
8/3/2019 Model FOC MAnual
3/43
MICROSOFT
WORD
MICROSOFT WORD
Word processor is used to produce documents for business or personal
use such as newsletter, reports, letters and essays. We might say that a word
-
8/3/2019 Model FOC MAnual
4/43
processor is an intelligent typewriter. We can type a whole page, make
corrections (editing), use up paragraphs in different styles and shapes and
columns (formatting) and also check spelling, find and insert synonyms for a
word (Thesaurus) and process it in many more ways before we actually put
that page to print.
FEATURES OF WORD PROCESSOR
The following are the main features of a word processor:
Fast
Editing features
Permanent storage
Formatting features
Graphics
CREATING A WORD DOCUMENT
AIM:
To create a document that reflects the newspaper format using Microsoft
word.
PROCEDURE:
-
8/3/2019 Model FOC MAnual
5/43
To enter Microsoft word, Click start button then click program
from programs menu then click Microsoft word
For opening a word document do the following. Click file menu
from the menu bar. From this file menu click new option. This will
display the new document.
Then for the newspaper format there must be a header and footer for
giving heading and page number. This is done by clicking view
from the menu bar, from this click header and footer option.
Then enter the heading in the header portion and change the font
size to big size and then click B button on formatting tool bar sothat the header appears bold.
Divide page into columns by clicking the format from the menu bar.
Then click columns from the menus available under format. In this
step the page is divided into your optional columns.
Then enter the text. To insert a picture in between the text, click
insert from the menu, then click picture and then clip art. From this
clip art we can insert any picture.
To insert symbols that are not found in the keyboard, click insert
from the menu, then click symbols.
After adding the text to the document, save the document by clicking
the file from the menu bar and click save .When we save the
document for the first time name is to be entered and click save
EXERCISE 1: Create the following document
-
8/3/2019 Model FOC MAnual
6/43
THE HINDU
FAKE STAMP PAPERS SEIZED
Two persons were arrested and counterfeit stamp papers seized
following a raid conducted on a house in coimbatore
A release here said a special team The team also found
Found counterfeit stamp papers of counterfeit currency.
Value Rs50000 and Rs1000.
EXERCISE 2:
Insert the following mathematical formula and equations in the document
(a+b)(a-b)=a2-b2
(a+b)2=a2+b2+2ab
2H2+O2->2H2O
Insert the symbols like , , in your document
EXERCISE 3:
To create a resume. Sample document is given below.
RESUME
-
8/3/2019 Model FOC MAnual
7/43
Name
Address Contact details with corresponding symbols
Objectives:
Educational Qualification:
Extra curricular activities:
Co-curricular activities:
Hobbies:
Personal profile:
Declaration:
Thanking you,
Yours truly,
CREATING A TABLE
AIM:
TO create a table using Microsoft word.
PROCEDURE:
-
8/3/2019 Model FOC MAnual
8/43
To enter Microsoft word, Click start button then click program
from programs menu then click Microsoft word
For opening a word document do the following. Click file menu
from the menu bar. From this file menu click new option. This will
display the new document.
Enter the heading, change the font size. Click the B button on the
formatting tool bar so that the heading appears bold.
To change the font colors clickA button on the drawing tool bar and
select the required colors.
To insert a table click Table from the menu, then click insert, thenclick table. Specify the required number of rows and columns and
the table gets inserted.
After adding the text to the document, save the document by clicking
the file from the menu bar and click save .When we save the
document for the first time name is to be entered and click save
Now the document has been created successfully.
EXERCISE 1: To create your class time table.
EXERCISE 2: Create a table having the following details: Student number,
name and marks.Mark1 and Mark2 are the two columns that should be in the
marks column.
CREATE A MERGED DOCUMENT
AIM:
TO create a merged document using Microsoft word.
-
8/3/2019 Model FOC MAnual
9/43
PROCEDURE:
To enter Microsoft word, Click start button then click program
from programs menu then click Microsoft word
Click Tools from the menu and choose Letters and mailings, then
click mail merge from it.
Then proceed with the following six steps to create a merged
document.
1. From the list of document types available choose letters
2. Select current document as the starting document3. Then select the recipients from the list. If the list is already
available choose Use an existing list otherwise choose Type
a new list and type the names & addresses of recipients
4. Write the content of the letter. To add recipient information to
the letter, click a location in the document and then click
Address block
5. One of the merged letter will be previewed and to preview
another letter click one of the following:
6. On clicking complete the mail merge mail merge is ready to
produce the letters
Now the document has been created successfully.
EXERCISE 1:
Using mail merge send the following letter to 5 of your friends.
From
Anto,
-
8/3/2019 Model FOC MAnual
10/43
B-62,13th cross street,
Rose apartments,
Ambattur,
Chennai.
To
Dear,
Sub: Invitation for party.
I hereby invite you and your family members for the 25th anniversary
of my parents that is to be held on 28-11-2008 at our home. Please do come
and share with us our joy. I will be disappointed in your absence.
Yours lovingly,
EXERCISE 2:
A college wants to invite all the old students for its old students association
to be held in the college. Prepare a mail merged letter, in which only the
address changes for every student and the body of the letter remains
unchanged.
FLOWCHARTAIM:
TO create a flowchart using Microsoft word.
PROCEDURE:
-
8/3/2019 Model FOC MAnual
11/43
To enter Microsoft word, Click start button then click program
from programs menu then click Microsoft word
For opening a word document do the following. Click file menu
from the menu bar. From this file menu click new option. This will
display the new document.
Enter the heading, change the font size. Click the B button on the
formatting tool bar so that the heading appears bold.
To change the font color clickA button on the drawing tool bar and
select the required colors.
Click Autoshapes option from the drawing tool bar, then clickflowchart and all the shapes will appear on the screen.
Select the needed shapes one by one and place it on the screen. To
connect all the boxes use flow lines from the drawing tool bar.
To add text inside the shape, select the particular shape and right click
the mouse button. Then a menu appears on the screen, select add
text from the menu. Now the cursor appears inside the shape and
allows us to enter the text.
Now the flowchart has been created successfully.
Exercise 1:
Draw a flowchart to calculate the simple interest.
Exercise 2:
Draw a flowchart to find the factorial of a given number using function.
-
8/3/2019 Model FOC MAnual
12/43
MICROSOFT
EXCEL
MS-EXCEL
-
8/3/2019 Model FOC MAnual
13/43
An electronic spreadsheet or spreadsheet is a table of rows and
columns into which data is entered. Spreadsheet software makes it
possible to enter data into a task format, manipulate, store, print
and create reports and graphics using them.
Microsoft Excel is the most widely used and versatile
spreadsheet package and lets you to organize your data into lists
and then summarize, compare and present the data graphically. It
has the user interface features common to other Microsoft office
applications.
MS-EXCEL allows you to
Enter and edit data in a worksheet
Use functions and formulae to calculate and analyze data
Create colorful charts and graphs
Save time by combining a series of commands into a single
command by using MACROS
CHART CREATION
-
8/3/2019 Model FOC MAnual
14/43
AIM:
TO create a chart for the given data.
PROCEDURE:
To enter Microsoft Excel, Click start button then click program
from programs menu then click Microsoft Excel
For opening a word document do the following. Click file menu
from the menu bar. From this file menu click new option. This will
display the new work sheet.
Enter the data by placing the mouse pointer in a cell and a double
click on it. Use the tab key to switch from one cell to another.
To insert charts select the data to which the chart should be created.
Now click insert chart icon. A window will appear and select the
appropriate chart from it. Click next and enter the title, category(x)
axis, category(y) axis etc. Click finish button.
Then the appropriate chart is placed in the worksheet.
EXERCISE 1:
-
8/3/2019 Model FOC MAnual
15/43
Compare the population (in the year 2007 and 2008) in the main cities
in India using various charts.
EXERCISE 2: Using various Charts compare the performance of 3
students in their examination. Create Line, XY, Bar, Pie charts for the
following data
NAME MARK1 MARK2 MARK3
Anto 96 85 45
Ignatius 80 59 85
Griffin 78 89 45
FORMULA EDITOR
AIM:
-
8/3/2019 Model FOC MAnual
16/43
To calculate HRA, DA, TA, PF, GPF, LIC, Gross salary, Deductions, Net
salary from the given data in a worksheet.
ENO Name Basic HRA TA DA LIC PF GPF GS DED NET
1 Abc 2000
0
2 Asd 1500
0
3 Bfr 1000
0
4 Cde 7820
5 Erg 4569
WhereHRA is 18% of basic
DA is 15% of basic
TA is 12% of basic
PF is 10% of basic
GPF is 5% of basic
LIC is 7% of basic
GS (Gross salary) =Basis+HRA+DA+TA
DED (Deduction) =PF+GPF+LIC
NET (Net salary) =GS-DED
PROCEDURE:
-
8/3/2019 Model FOC MAnual
17/43
To enter Microsoft Excel, Click start button then click program
from programs menu then click Microsoft Excel
For opening a word document do the following. Click file menu
from the menu bar. From this file menu click new option. This will
display the new work sheet.
Enter the data by placing the mouse pointer in a cell and a double
click on it. Use the tab key to switch from one cell to another.
For putting formulas, for eg,place the cursor on a cell which you have
to calculate the value of HRA, then type
=cell position of basic*18% and press enter.
Now the value of HRA is calculated. Similarly do for all others.
Calculate the same for other columns and drag them to all the cells.
Now the entire table is ready in spreadsheet.
-
8/3/2019 Model FOC MAnual
18/43
SPREAD SHEET-INCLUSION OF OBJECT, PICTURE &
GRAPHICS, PROTECTING THE DOCUMENT
AIM:
i. Insert object in the worksheet
ii. Insert picture in the worksheet
iii. Protect a sheet
PROCEDURE:
To enter Microsoft Excel, Click start button then click program
from programs menu then click Microsoft Excel
For opening a word document do the following. Click file menu
from the menu bar. From this file menu click new option. This will
display the new work sheet.
For inserting object in the worksheet, choose objects option in the
insert menu
For inserting picture in the worksheet, choose Picture option in theinsert menu
For protecting your worksheet, choose Protection option from Tools
menu, then choose Protect Sheet option, Protect sheet dialog box
appears. Type a password and press enter.
Now your worksheet is protected and can be entered only with the
password.
-
8/3/2019 Model FOC MAnual
19/43
SORTING AND IMPORT/EXPORT FEATURES
AIM:
i. Sort the given data in the worksheet
ii. Include Import/export features
PROCEDURE:
To enter Microsoft Excel, Click start button then click program
from programs menu then click Microsoft Excel
For opening a word document do the following. Click file menu
from the menu bar. From this file menu click new option. This will
display the new work sheet.
Select the data to be sorted and select data from the menu and click
sort
Specify the order in which the data are to be sorted (ascending or
descending) and click OK. Then the sorted data appears in the sheet.
To import a file select Insert->object->create from file
To export a file while saving the file save it as webpage so that it can
be viewed by internet explorer
EXERCISE 1:
-
8/3/2019 Model FOC MAnual
20/43
Sort the given data in ascending and descending order (consider the name).
NAME MARK1 MARK2 MARK3
Anto 96 85 45Ignatius 80 59 85
Griffin 78 89 45
EXERCISE 2:
Sort the list of 10 students according to their average where
Average=M1+M2+M3+M4+M5
-
8/3/2019 Model FOC MAnual
21/43
C PROGRAMMING
-
8/3/2019 Model FOC MAnual
22/43
SIMPLE PROGRAMS
1. TEMPERATURE CONVERSION
AIM:
To write a program to convert the Celsius into Fahrenheit.
Formula:
FAHRENHEIT= CELSIUS*1.8 +32
ALGORITHM:
Step 1: Enter the CELSIUS value.
Step 2: Calculate the FAHRENHEIT value by multiplying CELSIUS with
1.8 and add 32
Step 3: Print the FAHRENHEIT value.
-
8/3/2019 Model FOC MAnual
23/43
2. SIMPLE INTEREST CALCULATION
AIM:
To write a program to calculate the simple interest.
Formula:
Simple Interest = (P*N*R)/100
ALGORITHM:
Step 1: Read the principal amount P, interest rate R and period N.
Step 2: Calculate Simple Interest by multiplying principal amount P, interest
Rate R, period N and dividing by 100.
Step 3: Print the value of Simple Interest.
-
8/3/2019 Model FOC MAnual
24/43
3. SWAP USING TWO VARIABLES
AIM:
To perform swapping using two variables.
ALGORITHM:
Step 1: Read the two numbers a & b
Step 2: Perform
2.1 a = a + b;
2.2 b = a - b;
2.3 a = a - b;
Step 3: Print the numbers a and b
-
8/3/2019 Model FOC MAnual
25/43
CONDITIONAL STATEMENTS
4. ROOTS OF A QUADRATIC EQUATION
AIM:
To write a program to find the roots of the Quadratic Equation.
Formula:
D=B2-4AC
Condition 1: D= =0ROOT1=ROOT2= (-B+ D)/ (2*A)
Condition 2: D>0
ROOT1= (-B+D)/ (2*A)
ROOT2= (-B-D)/ (2*A)
Condition 3: D
-
8/3/2019 Model FOC MAnual
26/43
3.1 Print Roots are real and equal
3:2 Find the two roots as ROOT1 = (-B + SQRT ((D)) / (2*A)
3.3 Print the ROOT1 two times.
Step 4: If D is greater than zero then
4.1 Print Roots are real and unequal
4.2 Find the two roots as
ROOT1 = (-B + SQRT ((D)) / (2 * A)
ROOT2 = (-B SQRT ((D)) / (2 * A)
4.3 Print ROOT1 and ROOT2
Step 5: If D is less than zero then
5.1 Print the Roots are imaginary
5.2 Find the two roots as
X = (-B) / (2 * A)
Y=-D/ (2*A)
5.3 Print them in the format of (X + iY), (X iY)
5. ELECTRICITY BILL PREPARATION
-
8/3/2019 Model FOC MAnual
27/43
AIM
To write a program to prepare the electricity bill.
An electric power distribution company charges its domestic consumers as
follows:
CONSUMPTION UNITS RATE OF CHARGE
0-200 Rs.0.50 per unit
201-400 Rs 100+ Rs. 0.65 per unit excess of 200
401-600 Rs 230+ Rs. 0.80 per unit excess of 400
601 and above Rs 390+ Rs. 1 per unit excess of 600
ALGORITHM:
Step 1: Enter the value units
Step 2: If units are in the range 0-200
Charges=0.50*units
Step 3: If units are in the range 201-400
Charges=100 + 0.65*units
Step 4: If units are in the range 401-600
Charges=230 + 0.80*units
Step 5: If units are in the range 601 and above
Charges=390 + 1*unitsStep 6: Print the charges
6. REVERSING THE GIVEN NUMBER
-
8/3/2019 Model FOC MAnual
28/43
AIM:
To write a program to reverse the given integer using while loop.
ALGORITHM:
Step 1: Initialize SUM as 0
Step 2: Enter the number, N to be reversed
Step 3: While the number, N is not less than zero do
3.1 R = Find the remainder of N divided by 10
3.2 SUM = Multiply SUM by 10 and add to R
3.3 N = Find the Quotient of N divided by 10
Step 4: Print the value of SUM, which is the reversal of a given number.
7. ARMSTRONG NUMBER GENERATION
-
8/3/2019 Model FOC MAnual
29/43
AIM
To write a program to generate Armstrong numbers using do while loop.
ALGORITHM
Step 1: Get limit of the generation N
Step 2: Do the following for N times
Step 2.1: SUM = sum of cubes of each digit of original number
Step 2.2: If original number and SUM is same, then print the original
Number.
8. SINE SERIES CALCULATION
-
8/3/2019 Model FOC MAnual
30/43
AIM
To write a program to calculate Sine value using its series using for loop.
Formula:
Sin(x) =x - x3/3! +X5/5!-x7/7! +-----
Hint: Similarly do for the cosine series
Cos(x) =1-x2/2! +X4/4!-x6/6!
ALGORITHM
Step 1: Get a degree X and No of terms in the series to be generated N
Step 2: Assign X to Val, T, Sum for future purpose & the radian value of X
in X.
Step 3: Do the following for N+ 1 time
Step 3.1: Find out each term in the series T
Step 3.2: Find out sum of the terms T in SUM
Step 4: Print SUM as Sin(X).
ARRAYS
-
8/3/2019 Model FOC MAnual
31/43
9. SORTING THE GIVEN ARRAY OF NUMBERS
AIM
To write a program to sort the given array of numbers in ascending /
descending.
ALGORITHM
Step 1: Enter the size of the array N.
Step 2: Enter the elements of the array A.
Step 3: Set an outer loop up to N-1
Step 3.1: Set an inner loop up to N-1
Step 3.2: If first number is greater than next number, then swap them
Step 4: Print the ascending order of the given array (from 0th element to nth
element).
Step 5: Print the descending order of the given array (from nth element to 0th
element ).
10. MATRIX ADDITION
-
8/3/2019 Model FOC MAnual
32/43
-
8/3/2019 Model FOC MAnual
33/43
AIM
To write a program to multiply two matrices.
ALORITHM
Step1: Enter the row and column value
Step2: Enter the elements of the matrix A.
Step 3: Enter the elements of the matrix B.
Step 4: Print the matrix A in the matrix form.
Step 5: Print the matrix B in the matrix form.
Step 6: Set a loop up for row values (i)
Step 6.1: Set an inner loop up for column values (j).
Step 6.2: Set one more inner loop (k)
Step 6.3: Perform C[i] [j] = C[i] [j] + A[i] [k] * B[k] [j]
Perform the above for the various values of i, j and k
Step 7: Print matrix C.
STRUCTURES & UNIONS
-
8/3/2019 Model FOC MAnual
34/43
12. STUDENTS MARKS CALCULATION USING STRUCTURE
AIM
To write a program to prepare students mark list using structure.
ALGORITHM
Step1: Define the STUDENTS structure with details of Roll no, Name,
Marks
Step2: Get the number of students as N.
Step3: Declare a structure variable with size N.
Step4: Do the following for N times
Step4.1: Get the details of the student.
Step4.2: Calculate total, average, and Grade
Step4.3: Print the students individual Mark list with total, average
and Grade.
13. EMPLOYEE DETAILS USING STRUCTURE
-
8/3/2019 Model FOC MAnual
35/43
AIM
To write a program to prepare Employee pay slip using Structure.
ALGORITHM
Step1: Define the EMP structure with details of employee number, Name,
Basic.
Step2: Get the number of employees as N
Step3: Declare a structure variable with size N.
Step4: Do the following for N times
Step4.1: Get the details for an employees
Step4.2: Calculate Net Salary, Deduction and Gross Salary.
Step4.3: Print the employees pay slip with Net Salary, Deduction and
Gross Salary.
FUNCTIONS & RECURSION
-
8/3/2019 Model FOC MAnual
36/43
-
8/3/2019 Model FOC MAnual
37/43
ALGORITHM FOR DIV (A, B):
Step 1: Divide A by B and assign the result in G
Step 2: Return the variable, G.
ALGORITHM FOR DISPLAY (D):
Step 1: Display the value of D.
15. FIBONNACI SERIES
-
8/3/2019 Model FOC MAnual
38/43
AIM:
Using Recursion generate the Fibonacci series Up to for the given number.
Series:
0 1 1 2 3 5 8 13
ALGORITHM:
Step 1: Enter the number N.
Step 2: Initialise f=-1 and s=1
Step 3: Call the recursive function FIBO, with N, f and s as arguments.
ALGORITHM FOR FIBO (N,f,s):
Step 1: If N is greater than Zero
1.1 no=f+s
1.2 print the no
1.3 Call the recursive function FIBO, with N-1, s and no as
arguments.
-
8/3/2019 Model FOC MAnual
39/43
16. FACTORIAL
AIM:
Using recursion find the factorial of the given number.
ALGORITHM:
Step 1: Enter the number N.
Step 2: Call the recursive function FACT, with N as an argument.
Step 3: Print the returned value of a function FACT
ALGORITHM FOR FACT (K):
Step 1: If the number K is equal to 1, then return 1
Step 2: Otherwise call it recursively with N-1 as an argument and return it.
-
8/3/2019 Model FOC MAnual
40/43
-
8/3/2019 Model FOC MAnual
41/43
-
8/3/2019 Model FOC MAnual
42/43
-
8/3/2019 Model FOC MAnual
43/43