enter the number of lines to print : 10 · web viewthus the flowchart has been drawn using auto...

91
COMPUTER PRACTICE LABORATORY-I WORD PROCESSING 1

Upload: vuongdieu

Post on 10-May-2018

216 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

WORD PROCESSING

1

Page 2: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 1

Date :DOCUMENT CREATION

AIM

Create a document and Manipulate Text with Scientific notations.

PROCEDURE

I. Open a new document using File -> New option and type the text.

II. Bold, Italic, Underline, Spell check1. Select the word.2. Press CTRL+B or button on the formatting toolbar.3. Press CTRL+I or button on the formatting toolbar.4. Press CTRL+U or button on the formatting toolbar.5. Right click on the word, Click Spelling and Grammar on tools or button on the standard tool bar.

III. Saving the document1. Press CTRL+S or button on the standard tool bar or2. Select the Save option from the File menu. It shows the Save As

dialog box. Choose a suitable file name in File name text box. Then click save button on Save As dialog box.

IV. Alignment1. Select the text for alignment.2. Left alignment: Press CTRL+L or button on the formatting toolbar.3. Right alignment: Press CTRL+R or button on the formatting toolbar.4. Center alignment: Press CTRL+E or button on the formatting toolbar.5. Justification: Press CTRL+J or button on the formatting toolbar.

2

Page 3: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

V. Bullets and Numbering1. Select the text.2. Click Bullets button on the formatting tool bar or choose Bullets and Numbering option from the Format menu. The following dialog box appears.3. Choose required Bullet from the Bullet tab for Bullets.4. Choose Numbering button on the formatting tool bar or choose required number series from the Numbered tab in the Bullets and Numbering dialog box.

VI. Line Spacing1. Select the paragraphs of the document or choose Select All option from the Edit menu or by pressing CTRL + A.2. Choose paragraph option from the Format menu. A paragraph dialog box appears.3. Select the line spacing that is required then click ok.

VII. Font Type and Size1. Select the required text.2. Choose Font option from the Format menu. The Font dialog box appear as shown below. 3. Choose the required font type from the Font drop down list box and the required size from the Size list box on the Font Dialog box. Then click OK.

VIII. Inserting Symbols1. Type the text, then put the cursor where the symbol is to be inserted.2. Choose Symbols option from the Insert menu.3. It shows the Symbol dialog box. Then choose the appropriate Font type.4. Then choose the required symbol from the Symbols dialog box. Then click OK.

IX. Adding Animation to the text1. Type and select the required text.2. Choose Format -> Font option.3. Font dialog box is displayed, choose Text Effects tab.4. Choose the required animation and click OK.

X. Highlighting the Words in a Document

3

Page 4: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

1. Select the Text Highlight Color option from Font tool Bar.2. Select the word/ Text which you want to change the color.

OUTPUT

Characteristics of computers

SpeedComputers process data at extremely fast rate, at millions of instructions per second. A computer can perform a huge task that a normal human being may take days or even years to complete. The speed of a computer is calculated in MHz (MegaHertz) ie. One Million instructions per second.

2. AccuracyComputers are very accurate. The level of accuracy depends on the

instructions and type of machine being used. Faulty instructions for data

processing lead to faulty results. This is called GIGO (Garbage In Garbage

Out).Computer’s physical circuits rarely make errors, if the data and

instruction are correctly fed. Most of the errors occurring in computers are

either hardware errors or human errors.

Scientific Notation1. C2H6 + 3.5 O2 2 CO2 + 3 H2O

2. (X + Y)2 = X2 + Y2 + 2XY

RESULT

Thus the document has been created as per the format given.

4

Page 5: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 2

Date :TABLE CREATION AND MANIPULATION

AIMTo Create the Table Creations, Table formatting and Table

Conversion using Ms – Word.

PROCEDURE

I. Table Insertion1. Choose Table -> Insert ->Table option.2. It displays Insert Table dialog box.3. Choose the required number of rows and columns and then click OK.

II. Split and merge cells1. Select the cell to be splitted.2. Click Table menu from the Menu bar.3. Select Split cell option from the Layout menu in Table tools, the split cells dialog box appears.4. Enter the choice to split cells and click OK.5. Select the cells in the table for merging.6. Select the Merge cell option from the Layout menu in Table tools or click on the Merge cells button in the Tables and Borders toolbar.

III. Sorting the table contents1. Select the table to be sorted and choose Sort option from the Layout menu in Table tools.2. The sort dialog box is displayed.3. Choose the required column for sorting in the Sort list box and click OK.

IV. Splitting the table1. Select the row from which the table is to be divided.2. Choose Split table option from the Layout menu in Table tools.

5

Page 6: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

V. Calculations using formula1. Insert the table & type the required information.2. Place the cursor in the cell at which calculation result is to be displayed. For example, finding the maximum in a column).3. Choose Formula option from the Layout menu in Table tools, Formula dialog box is displayed.

VI. Auto formatting the table1. Select the table.2. Choose Table AutoFormat option in the Design menu which shows the Table Autoformat dialog box.3. Choose the required format from the Formats list box and click OK.

VII. Converting the table to text1. Select the table.2. Choose the Convert - > Table to Text options from the Layout menu in Table tools.3. Now it shows the Convert table to text dialog box.4. Choose the separator of the text and click OK.

VIII. Converting the text to table1. Select the text to be converted to table.2. Choose the Convert -> Text to Table option from the Table menu which shows the convert text to table dialog box.3. Choose the table size and separator text option and click OK.

6

Page 7: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

(I) Table Insertation

(II) Split Cell and Merge Cell

(III) Sorting the Table ContentSLNO NAME MARK1 MARK2 MARK3 TOTAL08CS05 Arunkumar 58 89 78 22508CS26 Prasath 45 90 75 21008CS43 Sivakumar 50 95 96 24108CS58 Abdul 52 87 98 237

(IV) Split the Table

(V) Calculation Using FormulaSLNO NAME MARK1 MARK2 MARK3 TOTAL08CS05 Arunkumar 58 89 78 22508CS26 Prasath 45 90 75 21008CS43 Sivakumar 50 95 96 24108CS58 Abdul 52 87 98 237

7

Page 8: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

(VI) Auto formatting the TableSLNO NAME MARK1 MARK2 MARK3 TOTAL

08CS05 Arunkumar 58 89 78 22508CS26 Prasath 45 90 75 21008CS43 Sivakumar 50 95 96 24108CS58 Abdul 52 87 98 237

(VII) Convert the Table to TextSLNO, NAME, MARK1, MARK2, MARK3, TOTAL08CS05, Arunkumar, 58, 89, 78, 22508CS26, Prasath, 45, 90, 75, 21008CS43, Sivakumar, 50, 95, 96, 24108CS58, Abdul, 52, 87, 98, 237

(VIII) Convert the Text to TableSLNO NAME MARK1 MARK2 MARK3 TOTAL

08CS05 Arunkumar 58 89 78 22508CS26 Prasath 45 90 75 21008CS43 Sivakumar 50 95 96 24108CS58 Abdul 52 87 98 237

RESULT

8

Page 9: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the table has been created, formatted and converted.

Ex. No. 3

Date : MAIL MERGE AND LETTER PREPARATION

AIMTo do mail merge and prepare letters using MS-Word.

PROCEDURE

I. Mail MergeA. Creating the main document1. on the menu bar, click on Tools-> Letters & Mailings-> Mail Merge...2. A task pane will appear on the right of the word document.3. Under Select document type, choose Letters4. Click on Next: Starting document at the bottom of the task pane

B. Selecting the starting document1. Under Select starting document, select Use the current document will allow you to start from the current document shown on the screen.2. Click on Next: Select recipients at the bottom of the task pane

C. Selecting recipients1. Under Select recipients, click Type a new list.2. Click Create..., the following window will appear.3. In the New Address List window, type the data you want to Include under Enter Address information; for example, title, names, and address information.4. To make another entry, click New Entry.5. Repeat steps 3 and 4 until you've added all the entries you want, and then click Close.6. In the Save Address List window, type a name for the data list in the File name field, and select a folder to save the list.7. Click Save.8. Click on Next: Write your letter.

9

Page 10: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

D. Formatting letter1. Type the text that you want to appear in every form letter.2. Insert merge fields where you want to merge names, addresses, and Other data from the data source (i.e. recipient list) by clicking anywhere you want in the main document to insert the field.3. Then click on More Items and insert individual field.4. click Next: Preview your letters.

E . Preview letters1. To preview the items in order, click the arrows under the Preview Your letters heading.2. To locate a specific item, click Find a recipient..., and then enter the criteria in the Find field.3. To change the list of recipients, click Edit recipient list..., and make Your changes in the Mail Merge Recipients window.4. Click on Next: Complete the Merge at the bottom of the task pane.

F. Complete the merge1. Click Edit individual letters2. In the Merge to New Document window, select the records you want To merge.3. Click OK.

II. Printing Labels1. Choose Tools->Envelopes and Labels option.2. It displays Envelopes and Labels dialog box.3. Type the Label Address in the Address box.4. Click on Full page of same label option.5. Click on New document.

III. Letter Wizard1. Choose Tools->Letter Wizard.2. It displays Letter Wizard Dialog box.

3. Choose the appropriate page design and Letter style and click OK.

10

Page 11: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

(I) Mail Merge Mail merged document 1 (Main document merged with the data source)

From: The Manager, Madhu Systems, No. 21 – 30, Third Floor, Mirinda Towers, Adyar, Chennai – 600 020.

To: S. Ajith, No 25, Second Cross Street, Radha Nagar, Anna Nagar, Chennai – 600 040

Dear Sir / Madam,

Sub: Interview call letter, requested regarding.

You are requested to attend the interview, for the post of Project Trainee, in our concern on the 21st of may at 10.00 A.M. Please bring all your original certificates for the interview along with 2 copies of your updated resume.

Thanking You,

Your sincerely,

(For Madhu Systems)

11

Page 12: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Mail merged document 2 (Main document merged with the data source)

From: The Manager, Madhu Systems, No. 21 – 30, Third Floor, Mirinda Towers, Adyar, Chennai – 600 020.

To: A. Vijay, No 32 / A, Third Main Road, Krishna Nagar, Egmore, Chennai – 600 08

Dear Sir / Madam,

Sub: Interview call letter, requested regarding.

You are requested to attend the interview, for the post of Project Trainee, in our concern on the 21st of may at 10.00 A.M. Please bring all your original certificates for the interview along with 2 copies of your updated resume.

Thanking You,

Your sincerely,

(For Madhu Systems)

12

Page 13: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

(II) Printing Labels

RESULT

13

Page 14: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the letter has been created for multiple recipients using mail merge.

Ex. No. 4

Date :DRAW - FLOWCHART

AIM

Draw a flowchart for addition of two numbers in MS word.

PROCEDURE

1. Choose Flowchart option in the Autoshapes menu of the Drawing toolbar in Insert menu.2. Choose the appropriate flowchart symbol. Then drag the Symbol in the document.3. Type the text in the symbol by Right-click then choose Add Text.4. Using the Arrow button Line style button Arrow style in the Drawing toolbar. Draw the lines connecting to the different flowchart symbols.5. Select all the flowchart symbols and lines in the document using the select object button, then Right-click to choose Grouping->Group.

14

Page 15: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

(I) Addition of Two Numbers

15

START

READ A, B

C = A + B

PRINT C

STOP

Page 16: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

(II) Software Development Life Cycle (SDLC)

RESULT

16

Page 17: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the flowchart has been drawn using Auto shape tools.

Microsoft Word shortcut keys

Below is a listing of all the major shortcut keys in Microsoft Word. See our main shortcut page if you're looking for other shortcut keys used in other programs.

Shortcut Keys Description

Ctrl + A Select all contents of the page.

Ctrl + B Bold highlighted selection.

Ctrl + C Copy selected text.

Ctrl + E Aligns the line or selected text to the center of the screen.

Ctrl + F Open find box.

Ctrl + I Italic highlighted selection.

Ctrl + J Aligns the selected text or line to justify the screen.

Ctrl + K Insert link.

Ctrl + L Aligns the line or selected text to the left of the screen.

Ctrl + M Indent the paragraph.

Ctrl + P Open the print window.

Ctrl + R Aligns the line or selected text to the right of the screen.

Ctrl + T Create a hanging indent.

Ctrl + U Underline highlighted selection.

Ctrl + V Paste.

Ctrl + X Cut selected text.

17

Page 18: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ctrl + Y Redo the last action performed.

Ctrl + Z Undo last action.

Ctrl + Shift + F Change the font.

Ctrl + Shift + > Increase selected font +1pts up to 12pt and then increases font +2pts.

Ctrl + ] Increase selected font +1pts.

Ctrl + Shift + < Decrease selected font -1pts if 12pt or lower, if above 12 decreases font by +2pt.

Ctrl + [ Decrease selected font -1pts.

Ctrl + Shift + * View or hide non printing characters.

Ctrl + <left arrow> Moves one word to the left.

Ctrl + <right arrow> Moves one word to the right.

Ctrl + <up arrow> Moves to the beginning of the line or paragraph.

Ctrl + <down arrow> Moves to the end of the paragraph.

Ctrl + Del Deletes word to right of cursor.

Ctrl + Backspace Deletes word to left of cursor.

Ctrl + End Moves the cursor to the end of the document.

Ctrl + Home Moves the cursor to the beginning of the document.

Ctrl + Spacebar Reset highlighted text to the default font.

Ctrl + 1 Single-space lines.

Ctrl + 2 Double-space lines.

Ctrl + 5 1.5-line spacing.

Ctrl + Alt + 1 Changes text to heading 1.

Ctrl + Alt + 2 Changes text to heading 2.

Ctrl + Alt + 3 Changes text to heading 3.

Ctrl + F1 Open the Task Pane.

18

Page 19: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

F1 Open Help.

Alt + Ctrl + F2 Open new document.

Ctrl + F2 Display the print preview.

Shift + F3Change the text in Microsoft Word from upper to lower case or a capital letter at the beginning of every word.

Shift + Insert Paste.

F4 Repeat the last action performed (Word 2000+)

F5 Open the find, replace, and go to window in Microsoft Word.

Ctrl + Shift + F6 Opens to another open Microsoft Word document.

F7 Spell and grammar check selected text and/or document.

Shift + F7 Runs a Thesaurus check on the word highlighted.

F12 Save as.

Shift + F12 Save.

Ctrl + Shift + F12 Prints the document.

Alt + Shift + D Insert the current date.

Alt + Shift + T Insert the current time.

Ctrl + Shift + = For Supercript

Ctrl + = For Subscript

In addition to the above shortcut keys users can also use their mouse as a method of quickly do something commonly performed. Below some are examples of mouse shortcuts.

19

Page 20: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Mouse shortcuts Description

Click, hold, and drag Selects text from where you click and hold to the point you drag and let go.

Double-click If double-click a word, selects the complete word.

Double-clickDouble-clicking on the left, center, or right of a blank line will make the alignment of the text left, center, or right aligned.

Double-click Double-clicking anywhere after text on a line will set a tab stop.

Triple-click Selects the line or paragraph of the text the mouse triple-clicked.

Ctrl + Mouse wheel Zooms in and out of document.

20

Page 21: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

SPREAD SHEET

21

Page 22: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 5

Date :

SPREAD SHEET - CHART- LINE, XY, BAR &

PIE

AIMTo draw Line, XY, Bar and Pie charts using MS- Excel.

PROCEDURE

I. Line Chart

1. Enter the data in the spreadsheet.2. Select the data and choose the insert tab.3. Click the Line option in the charts group. A list of Line chart sub- types appear.

4. Choose a sub-type. Excel creates a line chart and the chart tools context tabs appear.

5. Choose the Design tab. Click on the chart layout and chart style.6. Excel applies the layout and style to the chart.7. Select Switch Row/Column to switch the row and column of the chart.8. Click the Move Chart button.The Move Chart dialog box appears.Click the New sheet radio button and type the name of the new chart sheet. Excel creates a new chart sheet and places the chart on it.9. Choose the Layout tab. Click on the Chart title option to type the title of the chart.10. Similarly click on the Axis title option to type the title horizontally and Vertically.11. Click anywhere on the chart to end your entry.

II. Column Chart

22

Page 23: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

1. Enter the data in the spreadsheet.2. Select the data and choose the insert tab.3. Click the Column option in the charts group.A list of Column chart sub-types appear.

4. Choose a sub-type.Excel creates a Column chart and the chart tools context tabs appear.

5. Choose the Design tab. Click on the chart layout and chart style.6. Excel applies the layout and style to the chart.7. Select Switch Row/Column to switch the row and column of the chart.8. Click the Move Chart button.The Move Chart dialog box appears.Click the New sheet radio button and type the name of the new chart sheet. Excel creates a new chart sheet and places the chart on it.9. Choose the Layout tab. Click on the Chart title option to type the title of the chart.10. Similarly click on the Axis title option to type the title horizontally and Vertically.11. Click anywhere on the chart to end your entry.

III. Bar Chart

1. Enter the data in the spreadsheet.2. Select the data and choose the insert tab.3. Click the Bar option in the charts group.A list of Bar chart sub- types appear.

4. Choose a sub-type.Excel creates a bar chart and the chart tools context tabs appear.

5. Choose the Design tab. Click on the chart layout and chart style.6. Excel applies the layout and style to the chart.7. Select Switch Row/Column to switch the row and column of the chart.8. Click the Move Chart button.The Move Chart dialog box appears.Click the New sheet radio button and type the name of the new chart sheet. Excel creates a new chart sheet and places the chart on it.9. Choose the Layout tab. Click on the Chart title option to type the title of the chart.10. Similarly click on the Axis title option to type the title horizontally and Vertically.

23

Page 24: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

11. Click anywhere on the chart to end your entry.

IV. Pie Chart

1. Enter the data in the spreadsheet.2. Select the data and choose the insert tab.3. Click the Pie option in the charts group.A list of Pie chart sub- types appear.

4. Choose a sub-type.Excel creates a pie chart and the chart tools context tabs appear.

5. Choose the Design tab. Click on the chart layout and chart style.6. Excel applies the layout and style to the chart.7. Select Switch Row/Column to switch the row and column of the chart.8. Click the Move Chart button.The Move Chart dialog box appears.Click the New sheet radio button and type the name of the new chart sheet. Excel creates a new chart sheet and places the chart on it.9. Choose the Layout tab. Click on the Chart title option to type the title of the chart.10. Click anywhere on the chart to end your entry.

OUTPUT

24

Page 25: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

(I) Enter the data in the Spread Sheet

25

Page 26: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

RESULT

Thus the procedure for payroll preparation in MS Excel are studied and understood.

26

Page 27: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 6

Date :FORMULA USING IN SPREAD SHEET

AIMTo calculations using formula by formula editor in MS- Excel.

PROCEDURE

I. Calculation - Formula:1. Enter the data in the worksheet as follows2. Place the cursor in Calculate Cell, type (Ex: =SUM (B4:F4).)3. Copy the formulae for the remaining cells by dragging it.

II. Calculation – Formula Editor1. Click the Formulas Menu. A formula editor dialog box will

appear.2. Select the Category of the function. Ex. Most Recently used3. Select a SUM and AVERAGE function.4. Type the data range.5. Calculate the Sum and Average.

OUTPUT:

27

Page 28: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

28

Page 29: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

RESULT

Thus the total and average were calculated using Formulas.

29

Page 30: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 7

Date :INCLUSION OF OBJECT, PICTURE IN EXCEL

SHEET & PROTECT A EXCEL WORK SHEET

AIM To include the object, picture, graphics and protect the document and also the sheet.

PROCEDURE

I. Inserting the objects in the worksheet:1. Choose object option in the Insert menu.2. An Object dialog box will appear.3. Choose Create New option for inserting a new object. Select the object type and click ok.4. Choose Create From File option for inserting an object that already exist. Browse the file name and click ok.

II. Inserting a picture.1. Choose picture option in the Insert menu.2. Insert Picture dialog box appears.3. Choose the picture to insert into the worksheet and click on insert button.4. Now the selected picture is inserted into the worksheet.

III. Show the worksheet in 3D effect.1. Open the worksheet, using File -> open option.2. Now it opens the selected worksheet.3. Select the data range in the worksheet.4. Choose Format As Table option from Home menu.5. It shows the AutoFormat dialog box.6. Click on 3D Effects auto format.7. Now the worksheet is shown in 3D format style.

IV. Protect a sheet in MS-Excel.1. Click on cell, which you want to protect.2. Choose Protect sheet option from Review tab.3. It shows the protect sheet dialog box asking the password to protect sheet.

30

Page 31: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

4. Type the password click and ok. Then it asks for confirmation Password box. Type the same password again and then click ok.

5. Now the sheet is under protection.6. If you click on any cell to type, then the following message box appears by specifying the sheet under protection.7. To remove protection, choose Unprotect Sheet from Review tab

and then type the password to unprotect.8. Now the sheet is unprotected.

OUTPUT:

31

Page 32: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

32

Page 33: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

(II) Inserting the Picture from File (III) Worksheet in 3D Effect

(IV) Protect a Sheet

RESULT

Thus the procedure for inclusion of object, picture & protection of

particular worksheet are studied and understood.

33

Page 34: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 8

Date :

SORTING & IMPORT FEATURES IN

EXCEL WORK SHEET

AIM

To sort the data, import external data from access database and to export the data using MS-Excel.

PROCEDURE

I. Sorting1. Enter the required data and select the data to be sorted.2. Choose Sort option from the Data menu.3. It displays sort dialog box.4. Then choose the column name in sort by combo box and also choose Whether ascending or descending.5. Then click OK.

II. Importing External data1. Create a database in MS-Access.2. Choose Data-> From Access3. It displays the Select Data Source dialog box.4. Select the required data source and click open.

III. Save the File1. Open the workbook.2. On the File menu, click Save As.3. Now the Save As dialog box appears.4. In the File name box type a new name for the workbook.5. In the Save As type list, click a file format.6. Click on save button.

34

Page 35: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT:

(I) Sorting the Data in Worksheet (Ascending in Name)

(II) Creating Database in MS – ACCESS

(III) Importing External Data from MS - ACCESS

RESULT

Thus the procedure for sorting of given set of data in excel are

studied and under stood.

35

Page 36: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Microsoft Excel shortcut keys

Below is a listing of all the major shortcut keys in Microsoft Excel. See our main shortcut page if you're looking for other shortcut keys used in other programs.

Shortcut Keys Description

F2 Edit the selected cell.

F5 Go to a specific cell. For example, C6.

F7 Spell check selected text and/or document.

F11 Create chart.

Ctrl + Shift + ; Enter the current time.

Ctrl + ; Enter the current date.

Alt + Shift + F1 Insert New Worksheet.

Shift + F3 Open the Excel formula window.

Shift + F5 Bring up search box.

Ctrl + A Select all contents of the worksheet.

Ctrl + B Bold highlighted selection.

Ctrl + I Italic highlighted selection.

Ctrl + K Insert link.

Ctrl + U Underline highlighted selection.

Ctrl + 5 Strikethrough highlighted selection.

Ctrl + P Bring up the print dialog box to begin printing.

Ctrl + Z Undo last action.

Ctrl + F9 Minimize current window.

Ctrl + F10 Maximize currently selected window.

Ctrl + F6 Switch between open workbooks / windows.

36

Page 37: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ctrl + Page up Move between Excel work sheets in the same Excel document.

Ctrl + Page down Move between Excel work sheets in the same Excel document.

Ctrl + Tab Move between Two or more open Excel files.

Alt + = Create a formula to sum all of the above cells

Ctrl + ' Insert the value of the above cell into cell currently selected.

Ctrl + Shift + ! Format number in comma format.

Ctrl + Shift + $ Format number in currency format.

Ctrl + Shift + # Format number in date format.

Ctrl + Shift + % Format number in percentage format.

Ctrl + Shift + ^ Format number in scientific format.

Ctrl + Shift + @ Format number in time format.

Ctrl + Arrow key Move to next section of text.

Ctrl + Space Select entire column.

Shift + Space Select entire row.

37

Page 38: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

PROGRAMS USING C

38

Page 39: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 1

Date :FIND THE SIZE OF THE DATA

AIM

To write a program for finding the size of the data using C.

ALGORITHM

Step 1: Start the program.Step2: Initialize the datatype.Step3: Print the size of the data types using the statement sizeof()Step4: Stop the program.

PROGRAM

#include<stdio.h>#include<conio.h>main(){      int i=10;      float a,f=25.005;      char name[]="welcome";      clrscr();      printf("\nThe size of integer %d\n",sizeof(i));      printf("\nThe size of float %d\n",sizeof(f));      printf("\nThe size of name %d\n",sizeof(name));      getch(); } 

39

Page 40: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

The size of integer is...2The size of float is... 4The size of character is...8  

RESULT

Thus the program for finding the size of the data has been

implemented successfully.

40

Page 41: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 2

Date :

AREA AND CIRCUMFERENCE OF THE

CIRCLE

AIM

To write a program to find the area and circumference of the circle using C.

ALGORITHM

Step1: Start the program.Step2: Input the radius of the circle.Step3: Find the area and circumstance of the circle using the formula

Area=3.14*r*rCircumference=2*3.14*r

Step4: Print the area and the circumference of the circle.Step5: Stop the program.

PROGRAM

#include<stdio.h>      main()      {            float rad,area,circum;            clrscr();            printf("\nEnter the radius of the circle:");            scanf("%f",&rad);            area=3.14*rad*rad;            circum=2*3.14*rad;            printf("\nArea=%f",area);            printf("\nCircumference=%f",circum);            getch();      } 

41

Page 42: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter the radius of the circle5Area=78.500000Circumference=31.400000

RESULT

Thus the program for finding the area and circumference of the circle

has been implemented successfully.

42

Page 43: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Ex. No. 3

Date :FACTORIAL OF THE GIVEN NUMBER

AIM

To write a program to find the factorial of the given number using C.

ALGORITHM

Step1: start the program.

Step2: enter a number.

Step3: set a loop to find the factorial of the given number using formula

fact=fact*i

Step4: print the factorial of the given number.

Step5: stop the program.

PROGRAM

   #include<stdio.h>   main()   {            int fact=1,i,num;            clrscr();            printf("Enter the number:");            scanf("%d",&num);            for(i=1;i<=num;i++)            {                  fact=fact*i;            }            printf("The factorial of %d is %d",num,fact);            getch();   } 

43

Page 44: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter the number 5The factorial of 5 is 120 

 

RESULT

44

Page 45: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program to find the factorial of the given number has been

executed successfully.

Ex. No. 4

Date :

FIND THE LARGEST OF THE THREE

NUMBERS

AIM

Write a program to find the largest of the three numbers using C.

ALGORITHM

Step1: Start the program.

Step2: Read the three numbers a,b,c.

Step3: Assign the first number to the variable big.

Step4: Check whether the b is greater than big then assign b to

big.

Step5: Check whether the c is greater than big then assign c to

big.

Step6: Print the variable big.

Step7: Stop the program.

45

Page 46: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

PROGRAM

#include<stdio.h>main(){      int a,b,c,big;      clrscr();      printf("Enter the three numbers:");      scanf("%d %d %d",&a,&b,&c);      big=a;      if(big<b)            big=b;      if(big<c)            big=c;      printf("The biggest of three number is %d",big);      getch();}

46

Page 47: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter the three numbers 93 43 23The biggest of three number is 93 

RESULT

47

Page 48: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program to find the largest of three numbers has been

executed successfully.

Ex. No. 5

Date :

FIND THE SUM AND REVERSE OF THE GIVEN

NUMBER

AIM

Write a C program to find the sum and reverse of the given number.

ALGORITHM

Step1: Start the program.Step2: Initialize the variable as zero.Step3: If the number is not equal to zero then the corresponding operation will be performed.

Step4: Print the sum of the digits, reverse of the number.Step5; check whether the number is palindrome or not.Step6: stop the program.

PROGRAM

#include<stdio.h>main(){      unsigned long int a,num,sum=0,rnum=0,rem;      clrscr();      printf("\nEnter the number...");      scanf("%ld",&num);      a=num;      while(num!=0)      {            rem=num%10;            sum=sum+rem;            rnum=rnum*10+rem;            num=num/10;      }      printf("\nThe sum of the digits of %ld is %ld\n",a,sum);

48

Page 49: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

      printf("\nThe reverse number of the %ld is %ld",a,rnum);      if(a==rnum)            printf("\nThe given number is a palindrome");      else            printf("\nThe given number is not a palindrome");      getch();

OUTPUT

Enter the number...12321The sum of the digits of 12321 is 9The reverse number of the 12321 is 12321The given number is a palindrome 

RESULT

49

Page 50: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program to find the sum and reverse of the given number

has been executed successfully.

Ex. No. 6

Date :

ASCENDING AND DESCENDING ORDER OF

THE GIVEN NUMBERS

AIM

Write a Program to find the ascending and descending order of the

given numbers using C.

ALGORITHM

Step1: Start the program.

Step2: Enter the size of the array.

Step3: Enter the elements of the array.

Step4: Set a loop up to the array size minus one.

Step5: Set a inner loop up to the array size.

Step6: Check whether the next away elements is greater than or not.

Step7: If greater than exchange this position.

Step8: If not greater than goto the loop.

Step9: After the execution of the inner loop, the outer loop is executed.

Step10: Print the ascend order of the given array.

Step11: Print the descending.

Step12: Stop the program.

50

Page 51: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

PROGRAM

#include<stdio.h>main(){      int num[100],no,i,j,a;      clrscr();      printf("Enter Upper Limit...");      scanf("%d",&no);      printf("Enter the numbers");      for(i=0;i<no;i++)            scanf("%d",&num[i]);            for(i=0;i<no-1;i++)            {                  for(j=i+1;j<no;j++)                  {                        if(num[i]<num[j])                        {                        a=num[i];                        num[i]=num[j];                        num[j]=a;                  }            }}printf("\nThe ascending order of the given numbers");for(i=0;i<no;i++)      printf("\n%d",num[i]);printf("\n The descending number of the given numbers");for(j=no-1;j>=0;j--)      printf("\n%d",num[j]);getch();} 

 

51

Page 52: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter the number how many number you want to sort5Enter the numbers 10  30  50           60   20 The ascending order of the given numbers10    20  30  50  60The descending number of the given numbers60  50 30 20 10 

RESULT

52

Page 53: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program to find the ascending and descending of the given

number has been executed successfully.

Ex. No. 7

Date :MULTPLICATION OF TWO MATRIX

AIM

To write a C program to implement the multiplication of two matrix.

ALGORITHM

Step1: Start the program.

Step2: Enter the row & column of the matrix.

Step3: Enter the elements of the A matrix.

Step4: Enter the elements of the B matrix.

Step5: print the A matrix in the matrix form.

Step6: print the B matrix in the matrix form.

Step7: Set a loop up to the row.

Step8: Set a inner loop up to the column.

Step9: Multiply the elements of A and B in column wise.

Step10: After the execution of the two loops, print the value of c matrix.

Step11: Stop the program.

53

Page 54: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

PROGRAM

#include<stdio.h>main(){      int a[25][25],b[25][25],c[25][25],i,j,k,r,s;      int m,n;      clrscr();      printf("\nEnter the Rows and Columns of A matrix...");      scanf("%d %d",&m,&n);      printf("\nEnter the Rows and Columns of B matrix...");      scanf("%d %d",&r,&s);      if(m!=r)            printf("\nThe matrix cannot multiplied");      else      {            printf("\nEnter the elements of A matrix");            for(i=0;i<m;i++)            {                  for(j=0;j<n;j++)                  scanf("\t%d",&a[i][j]);            }            printf("\nEnter the elements of B matrix");

            for(i=0;i<m;i++)            {                  for(j=0;j<n;j++)                  scanf("\t%d",&b[i][j]);            }            printf("\nThe elements of A matrix");            for(i=0;i<m;i++)            {                  printf("\n");                  for(j=0;j<n;j++)                  printf("\t%d",a[i][j]);            }

54

Page 55: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

            printf("\n The elements of B matrix");            for(i=0;i<m;i++)            {                  printf("\n");                  for(j=0;j<n;j++)                  printf("\t%d",b[i][j]);            }            for(i=0;i<m;i++)            {                  printf("\n");                  for(j=0;j<n;j++)                  {                        c[i][j]=0;                        for(k=0;k<m;k++)                        c[i][j]=c[i][j]+a[i][k]*b[k][j];                  }            }      }      printf("The multiplication of two matrixes");      for(i=0;i<m;i++)      {            printf("\n");            for(j=0;j<n;j++)            printf("\t%d",c[i][j]);      }      getch();} 

55

Page 56: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter the Rows and Columns of A matrix... 3 3Enter the Rows and Columns of B matrix... 3 3Enter the elements of A matrix 1 2 3 4 5 6 7 8 9 Enter the elements of B matrix 1 2 3 4 5 6 7 8 9 The elements of A matrix      1 2 3      4 5 6      7 8 9The elements of B matrix      1 2 3      4 5 6      7 8 9The multiplication of two matrixes      30 36 42       66 81 96       102 126 150 

RESULT

56

Page 57: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program for multiplication of two matrix was written and

executed successfully.

Ex. No. 8

Date :MENU DRIVEN PROGRAM

AIM

To write a C program to perform menu driven program.

ALGORITHM

Step1: Start the program.

Step2: Read the values of num

Step3: Assign the value of 1 to Factorial similarly 2 to prime no, 3 to odd or

even and 4 to Exit.

Step4: Read the value of choice.

Step5: If choice is 1 then factorial of the given number is executed by the

formula fact=fact*i

Step6: If choice is 2 then it executes the given number is prime or not.

Step7: If choice is 3 then it executes the given number is odd or even.

Step8: If the choice is 4 then it exit from the program.

Step9: Stop the program.

57

Page 58: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

PROGRAM

#include<stdio.h>#include<conio.h>main(){      int num,o,i;      long int fact;      clrscr();      while(1)      {            printf("\nEnter the number ");            scanf("%d",&num);            printf("\nchoose one of the options given below");            printf("\n 1.Factorial of the given number \n 2.Prime number or not\n     3. Odd or Even \n 4. Exit");            scanf("%d",&o);            switch(o)            {                  case 1:                        fact=1;                        for(i=1;i<=num;i++)                        fact=fact*i;                        printf("The factorial of %d is %ld",num,fact);                        break;                  case 3:                        if(num%2==0)                           printf("The given number is Even number");                        else                           printf("The given number is Odd number");                        break;                  case 2:                        i=2;                        while(i<=num-1)                        {                              if(num%i==0)                        {                        printf("The given number is not a prime number");

58

Page 59: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

                        break;                  }            i++;            }            if(i==num)                  printf("The given number is a prime");            break;default:            exit(0);            }      }      getch();} 

59

Page 60: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter the number .. 5Choose one of the options given below1. Factorial of the given number2. Prime number or not3. Odd or Even4. Exit1The factorial of 5 is 120Enter the number..5Choose one of the options given below1.Factorial of the given number2.Prime number or not3.Odd or Even4.Exit2The given number is a primeEnter the number...5Choose one of the options given below1.Factorial of the given number2.Prime number or not3.Odd or Even4.Exit4

RESULT

60

Page 61: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program to perform the menu driven concept has been executed

successfully.

Ex. No. 9

Date :

STUDENT RECORD USING POINTER AND

STRUCTURE

AIM

To write a C Program to perform the student record using pointer and

structure.

ALGORITHM

Step1: Start the program.

Step2: Initialize the structure variable.

Step3: Enter the number of student.

Step4: Set a loop up to the number of student.

Step5: Enter the student name, roll no, average and marks.

Step6: Find their grades.

Step7: Print the student name, roll no, average and their grade.

Step8: Stop the program.

61

Page 62: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

PROGRAM

#include<stdio.h>#include<conio.h>main(){      struct student      {            char name[25];            char regno[25];            int avg;            char grade;      } stud[50],*pt;      int i,no;      clrscr();      printf("Enter the number of the students...");      scanf("%d",&no);      for(i=0;i<no;i++)      {            printf("\n student[%d]  information:\n",i+1);      printf("Enter the name");      scanf("%s",stud[i].name);      printf("\nEnter the roll no of the student");      scanf("%s",stud[i].regno);      printf("\nEnter the average value of the student");      scanf("%d",&stud[i].avg);      }      pt=stud;      for(pt=stud;pt<stud+no;pt++)      {            if(pt->avg<30)                  pt->grade='D';            else if(pt->avg<50)                  pt->grade='C';            else if(pt->avg<70)                  pt->grade='B';            else                  pt->grade='A';

62

Page 63: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

      }      printf("\n");      printf("NAME REGISTER-NO AVERAGE GRADE\n");      for(pt=stud;pt<stud+no;pt++)      {            printf("%-20s%-10s",pt->name,pt->regno);            printf("%10d \t   %c\n",pt->avg,pt->grade);      }      getch();} 

63

Page 64: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter the number of the students 3student[1]  information:Enter the name MUNIEnter the roll no of the student 100Enter the average value of the student 95student[2]  information:Enter the name LAKEnter the roll no of the student 200Enter the average value of the student 55student[3]  information:Enter the name RAJAEnter the roll no of the student 300Enter the average value of the student 25NAME  REGISTER-NO  AVERAGE  GRADE MUNI  100    95   ALKA  200    55   B   RAJA  300   25    D 

RESULT

64

Page 65: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program for creation of student record using structure and

pointer has been executed successfully.

Ex. No. 1O

Date :EMPLOYEE DETAILS USING UNION 

AIM

To write a C program to print the mark sheet of n students using

structures.

ALGORITHM

Step1: Start the program.

Step2: Declare the union variables.

Step3: Enter the employee name , number and salary.

Step4: Call the union function using union variables.

Step5: Print the details of the employees.

Step6: Stop the program.

65

Page 66: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

PROGRAM

#include<stdio.h>#include<conio.h>union uemf{      char name[10];      int number;      float sal;};main(){ union uemf u1;      clrscr();      printf("Enter the employee name...");      scanf("%s",u1.name);      printf("%s",u1.name);      printf("\nEnter the employee number...");      scanf("%d",&u1.number);      printf("%d",u1.number);      printf("\nEnter the salary...");      scanf("%f",&u1.sal);      printf("\%f",u1.sal);      getch();  } 

66

Page 67: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter the Employee name: ManishManishEnter the Employee number: 11111111Enter the Salary: 3455534555

RESULT

67

Page 68: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program for printing employee details using union was written

and executed successfully.

Ex. No. 11

Date :

ADDITION OF GIVEN TWO NUMBERS USING

FUNCTION

AIM

To Write a Program for Addition of given two numbers using function

ALGORITHM

Step1: Start the program.

Step2: Read the input from the user.

Step3: Transfer the control to the called function.

Step4: Perform the addition operation & return value to the calling function.

Step5: Print the result.

Step6: Stop the program.

68

Page 69: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

PROGRAM

#include <stdio.h>#include <conio.h>int main (){int add(int,int);int a,b,c;printf("Enter Any Two Numbers");scanf("%d%d",&a,&b);c=add(a,b);printf("The addition of given Two Number is %d",c);}int add(int x, int y){int z;z=x+y;return(z);}

69

Page 70: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

OUTPUT

Enter Any Two Numbers 5 5

The addition of given Two Number is 10

RESULT

70

Page 71: Enter the number of lines to print : 10 · Web viewThus the flowchart has been drawn using Auto shape tools. Microsoft Word shortcut keys Below is a listing of all the major shortcut

COMPUTER PRACTICE LABORATORY-I

Thus the program for printing addition of two numbers using function

was written and executed successfully.

71