Sei sulla pagina 1di 61

Department of Applied Science (Chemistry)

LAB MANUAL
SUBJECT: BCPC [CSP-133]

B.E First Year I / II Semester

Chandigarh University,
Gharuan (Mohali)

Table of Contents
S.No

Name of Experiment

Page
No.

UNIT-I
1

Introduction & demonstration of various components of


computer: Introduction to windows: user interface, icon,
folder and its features, installing window7, features and
various settings in windows, navigation with drives;
creating and sharing of folders, moving files into folders;
remote desktop connection.
Working with MS-Word:
Basics opening document, saving and closing, text creation
and editing, concept of headers & footers, use of formatting
features, working with tables; create a resume using word
processor.
Working With MS-Excel:
Basics, elements of electronic spread sheet, manipulation of
cells, providing formulas, insertion/deletion of
columns/rows; using spread sheets for small accountings,
creation of various charts; create a spread sheet consisting
of total marks of student in different subjects and calculate
the percentage for same.
Working with MS-PowerPoint:
Basics, creating presentation, preparation of slides and slide
show, slide manipulation, use of design templates, adding
pictures/clip art, diagram, tables & charts in slides; create a
power point presentation on any topic. .
UNIT-II
Programs for displaying messages as output.
5.1 To print messages on screen using escape sequence.

1-7

8-23

24-31

32-35

36-36

Programs based on conditional statements.


6.1. To find that given number is even or odd.
6.2
To find the greatest among three numbers using if else
statement.

6.3
To add, subtract, multiply, divide using switch
statement.
Programs based on loops and jumping statements.
7.1 To print pyramid for different patterns using for loop.
7.2 To print the table of a given number using while/ do
while loop.
7.3 To print the factorial of a number.

Department of Applied Science

37-39

42-43

Program based on functions with use of recursion and


argument passing.
8.1 To swap two numbers using call by value & call by
reference.
8.2 To print the sum of first n natural numbers by using
recursion.

44-46

UNIT-III
9

Program based on single dimensional and two dimensional


arrays.

47-50

9.1 To display the biggest value in an integer array.


9.2 To multiply two matrices using arrays.
Program based on the use of string functions.
10

10.1 To concatenate two strings & store the result in third


string.
10.2 To check whether the string is palindrome a) without
using string inbuilt functions b) with using string inbuilt
functions.

51-53

Program based on structure and union.


11

12

11.1 To read & print the record of 5 students using


structures.
11.2 To implement the concept of union.

54-56

Program based on files for various file operations.


57-58

12.1 To copy the contents of one file to another file.

Submitted By:

(Lakhindra Kumar)
Roll no. 46 I.Sc. Physical

(Dr. Madhav Kumar)


Vice Principal

Date: 2/8/2013

Department of Applied Science

Page 1 of 58

Experiment 1

Title: basics of Keyboard, Mouse, Motherboard, RAM, Hard disk, Different printers.
Objective: Providing basic information so that students become familiar to various
peripheral devices.

S/W Requirement: Operating System


H/W Requirement: Keyboard, Mouse, CPU, Motherboard, RAM, Hard disk, printers.
Theory:
RAM: Random Access Memory (RAM): allows data and instructions to be accessed randomly
from any memory location (address). Primary storage.
Volatile - lost when power is turned off

Motherboard: Attachments to the motherboard include:


Main Memory: types of main memory include:
RAM - temporary (includes virtual memory storage). Include RAM cache
ROM - permanent
When add main memory, make sure add-on chips are compatible
Real time clock (current date and time)
Microprocessor or CPU (central processing unit)
Control Unit: traffic cop portion of the CPU
ALU: arithmetic logic unit processes all math and logical operations performed by the
computer

CPU: Control Unit: works with the operating system to move data between auxiliary storage
and main memory; and between main memory and the ALU
Arithmetic/Logic Unit (ALU): processes data arithmetically (addition, subtraction,
multiplication, division) or logically (greater than, less than, equal to)
Main Memory: contains both program instructions and the data that is required.
A single machine can have multiple CPUs to share processing tasks (co-processors,
multiprocessing), but each CPU can execute only a single task.

Keyboard: Windows PCs use tow basic types of keyboards that are classified by the number
of keys they have:
101-key Enhanced keyboard
104-key Windows keyboard
The windows keyboard has some extra keys that address windows specific functions
such as opening the start menu or opening the shortcut menu.
Many new style keyboards also include keys or buttons for connecting to the internet,
sending and receiving emails, and adjusting the volume of the sound system separate
software needed to manage them.

Page 2 of 58

Mouse: Parts of a typical mouse:


Right Button
Left Button
Scroll Wheel
Mouse terms:
Right Click - clicking the right mouse button once
Left Click - clicking the left mouse button once
Double-click - clicking a button twice in rapid succession
Dragging - holding a button down over an object while moving the mouse
Dropping - letting the mouse button up after a drag

Printer:
A computer printer, or more commonly a printer, is a computer peripheral which produces
a hard copy (permanent human-readable text and/or graphics) of documents stored in
electronic form, usually on physical print media such as paper or transparencies. Many printers
are primarily used as local peripherals, and are attached by a printer cable to a computer which
serves as a document source. Some printers, commonly known as network printers, have
built-in network interfaces (typically wireless or Ethernet), and can serve as a hardcopy device
for any user on the network. Individual printers are often designed to support both local and
network connected users at the same time.
Different Types are:
Dot Matrix
Ink jet printer
Laser Printer

Introduction to windows
Windows
The Desktop
The word desktop has been derived from real life desk top were a manager puts all the things
required by her. For instance, on a desktop, there may be pen stand, notepad, calculator, etc.
Lying, which are required by the manager. The desktop of a Windows also serves the same
purpose.

Department of Applied Science

Page 3 of 58

WINDOWS DESKTOP
In Windows Operating System, the screen upon which icons, Windows, etc. are displayed is
known as desktop. The Windows Operating System desktop may contain a background, one
or more active or inactive windows, a taskbar and icons. A background can be anything from
a single- color screen to an elaborate artistic image. All windows and icons are superimposed
on the background, whatever it may be.

The Icons
Icons are the pretty pictures representing Windows elements like files, folders, shortcuts, etc.
Icons play a very important role in graphical user interface.

Commonly used icons are:


1. Application icons: These are the graphic rendering of the software packages logo.
If you double click over this icon, the related application gets invoked.

Department of Applied Science

Page 4 of 58

2. Shortcuts icons: These are little graphics pointing to a particular application,


document or folder, etc. By double clicking over them the concerned
application/document/folder etc. becomes active.

3. Document icons: The active document window,


which is a window within an
application window, can be minimized to a document icon. Point and double click on
the document icon to restore the document window.

4. Disk-drive icons: Disk-drive icons graphically represent five disk drive options:
floppy disk, hard-disk, network, Ram, and CD-ROM. The floppy disk,

DISK DRIVE ICONS

Hard-disk and CD-ROM icons resemble the faceplates of the disk drives. Typically, PCs
have only one or two floppy drives, assigned to A and B.

The Taskbar
This is bar that is usually found at the bottom of your screen. The start button about which
we have discussed just now is located on the task bar only.
Apart from the start button, the taskbar hosts the clock, some toolbar and the buttons
corresponding to all open windows.
Department of Applied Science

Page 5 of 58

Buttons on the taskbar show you which windows are open, even if some windows are
minimized or hidden beneath another window. You can easily switch to a different window
by clicking its taskbar button. That is, if you are currently working in Microsoft Excels
window and now you want to switch to Microsoft PowerPoint, which is also active in
another window, then, all you need to do is: click the button representing Microsoft
PowerPoint on the taskbar.

The Start Button


Using start button, we can accomplish almost any task. We can start programs, open
documents, customize system, get Help, search for items on our computer, and more. Some
commands on the start menu have right-facing arrow which means additional choices are
available on a secondary menu. If we place our pointer over an item with an arrow, another
menu appears.

To use the Start Menu


1. Click the start button. The start menu appears.
2. Click the option you want to open. Point to option with right-facing arrows to open
secondary menu.

Starting and Closing Programs

Department of Applied Science

Page 6 of 58
Most of the programs on the computer are available one convenient location- the Programs
section of the Start menu. Depending on how your computer is set up, what you see on the
Start menu varies.

To start a program
(MS Paint located on Accessories Group)
1. Click the start button, and then point to programs. The programs sub-menu appears.
2. Point to the group such as Accessories here that contains the program you want to start
and then click the program name i.e., on MSPaint in our case.

To quit an open program


1. Just click the close button in the upper-right corner of the program window
2. Alternatively, you can also click upon Exit option available on the File menu of the
application or you can also press the shortcut key Alt+F4.

Window control buttons


You can work with open windows in Windows 98 by clicking one of the window control
buttons located on the far right of the title bar.

MINIMIZE:

It
is
used
to
minimize
a
window.
minimized window is still open, and a window button appears on the taskbar.

RESTORE: Return a window to its previous size i.e., the original size in which it
was opened.

CLOSE: It is used to close the window.


Control Panel

Department of Applied Science

Page 7 of 58

This is used to change the settings of your computer. When you click on the Control Panel on
Task bar windows showing the contents of it appears.

Conclusion: Students are made familiar with various I/O devices and components of CPU
through the demonstration and with the windows operating system, its icons and menus and
Control Panel through the working.

Department of Applied Science

Page 8 of 58

Experiment 2
Title: Practice with MS Word, Operating and closing document, Preparation of document,
setting of document, familiarization with various tools, mail- merge practice.

Objective: To understand the Word in depth like creating, editing, formatting and printing
the documents and to understand its good tools like Mail merge

S/W Requirements: MS-Office (MS-Word)


H/W Requirements: Keyboard, Mouse, Monitor.
Introduction to MS- word
Microsoft Word is Microsoft's flagship word processing software. It was first released in 1983
under the name Multi-Tool Word for xenix systems. It is a component of the Microsoft
system; however, it is also sold as a standalone product and included in Microsoft works suite.
Beginning with the 2003 version, the branding was revised to emphasize Word's identity as a
component within the Office suite; Microsoft began calling it Microsoft Office Word instead
of merely Microsoft Word. The latest release is Word 2008 for Mac OS X.

Starting Microsoft Word

Two Ways
1. Double click on the Microsoft Word icon on the desktop.
2. Click on Start --> Programs --> Microsoft Word

Page 9 of 58

Special Features of MS word

Creating a new document

Toolbars

Formatting

Editing

Shortcuts

Other helpful functions

Department of Applied Science

Page 10 of 58

CREATING A NEW DOCUMENT


Many of the steps you are about to read are for both PC and Mac computers. Some of the steps
have very similar descriptions. For your benefit, this tutorial has combined the information but
will offer different screen shots for each system when necessary.

OPENING MICROSOFT WORD ON A PC


To launch Microsoft Word, go to Start > Programs > Microsoft Office > Microsoft Office
World. A blank Word document will open.

Navigate to Microsoft Word on a PC TOOLBARS


Microsoft Word uses toolbars to allow you to modify your document. When you first open
Word, usually the three toolbars discussed below will open. However, each computer may set
up these toolbars differently, so they will usually look different than the toolbars below. If you
do not see these toolbars, or to open up other toolbars, go to View Toolbars and place a
checkmark by the toolbar you wish to open. If you do not see an icon you expect on a toolbar,
click on the arrow at the end of the toolbar to reveal hidden icons. Word will also allow you to
customize your toolbars by going to View > Toolbars> Customize.

THREE COMMONLY USED TOOLBARS


Department of Applied Science

Page 11 of 58

The Menu bar: This toolbar is constructed of word commands and not icons (pictures).
The Menu bar contains all the options available to you in Microsoft Word. Using this toolbar
to format and change your document will often allow you greater control than using the icons
on the other toolbars. However, the other toolbars may be more convenient.

Menu bar.
The Standard toolbar: This toolbar contains icons from common commands such as
Save, Print, Tables, and Spell Check. These icons are convenient but will not bring up the
dialogue boxes that allow you to change the settings of these actions. You should use
whichever method works the best for you.

Standard toolbar.

The Formatting toolbar: This toolbar contains icons for common formatting actions,
such as Font Style, Font Size, Bold, Italic, Underline, Alignment, Numbered List,
Bulleted List, Indentation, Spacing, and Font Color. These icons are convenient but will
not bring up dialogue boxes that allow you to change the settings of these actions. You
should use whichever method works the best for you.

Formatting toolbar.
FORMATTING

Department of Applied Science

Page 12 of 58

FORMATTING THE DOCUMENT


The default page margin for Microsoft Word documents is 1.25 inches, not the 1 inch
normally required by instructors. Therefore, it is necessary to change the page margins of your
document. To do this on a Mac, go to Format > Document. To change the page margins on a
PC, go to File > Page Setup >

Margins. A menu will appear where you can type the desired margin size

Changing Margins in the Document Format Menu

Department of Applied Science

Page 13 of 58
From the same menu (Figure 1), select Layout to customize the layout of your document.
Click on Page Setup, and then select the orientation of your document. Click Portrait if you
want your document to be 8.5 x 11 inches (most common). Click Landscape if you want your
document to be 11 x 8.5 inches. Landscape simply flips the page 90 degrees.

FORMATTING PARAGRAPHS
To format your paragraph, first highlight the paragraph you wish to format. To highlight more
than one paragraph, click at the beginning of the paragraph and drag the mouse over the text.
To apply changes to the entire document, go to Edit > Select All. To specify Alignment, Line
Spacing, Indentation, and Page Break click Format > Paragraph. This will open up the
Paragraph menu (Figure 2). The Alignment option allows you to choose how you want your
paragraph to look (i.e. justified, right, center, or left). The Line Spacing option allows you to
set the desired spacing, such as single or double. The Indentation option allows you to
tab/push the line(s) in your paragraph either left or right. The Page Break option is found in
Paragraph menu, but you must first select the Line and Page Breaks tab. Page break allows
you to split a paragraph or a page up into sections. You can also bring up this menu by right
clicking (or by hitting CONTROL + click on a one button mouse) within the document and
selecting Paragraph.

Changing the Paragraph attributes with the Paragraph menu.

Department of Applied Science

Page 14 of 58

FORMATTING TEXT
Before you type, you should select your font style, size, color and attributes (such as bold, italic
and underline) by using the Formatting toolbar or by going to Format > Font. This will open
the Font menu (Figure 3). However, if you wish to change text that has already been typed,
click and drag over the text to be changed to highlight it (or go to Edit > Select All to select
the entire document) and change it as before.

Changing the font attributes in the Font menu.


NUMBERED AND BULLETED LISTS
To create a simple numbered or bulleted list, click on the Number or Bullet button on the
Formatting toolbar. To have more control over the format of your list, go to Format > Bullets
and Numbering. This will open up the Bullets and Numbering Menu. Select your desired
list format and click OK. Type the first item in the list and press RETURN to move to the next
number or bullet. Press RETURN twice to exit the list.

Department of Applied Science

Page 15 of 58

EDITING
Cut and Paste
In Microsoft Word, you can cut (delete) text from one area of a document and save that text so
it can be pasted elsewhere in the document. When you cut text, it is stored on the Clipboard.
You can also copy text. When you copy text, it is also stored on the Clipboard. Information
stored on the Clipboard stays there until new information is either cut or copied. Each time you
execute Cut or Copy, you replace the old information on the Clipboard with whatever you just
cut or copied. You can paste Clipboard information as often as you like.

Cut - Using the Menu


1. Type the following:
I want to move. I am content where I am.
2. Highlight "I want to move."

3. Choose Edit > Cut from the menu.


4. Your text should now read:
"I am content where I am."

Paste - Using the Menu


1. Place the cursor after the period in the sentence "I am content where I am."
2. Press the spacebar to leave a space.
3. Choose Edit > Paste from the menu.
4. Your text should now read
"I am content where I am. I want to move.

Copy and Paste


In Microsoft Word, you can copy text from one area of the document and place that text
elsewhere in the document. As with cut data, copied data is stored on the Clipboard.

Department of Applied Science

Page 16 of 58

Copy - Using the Menu


1. Type the following:
You will want to copy me. One of me is all you need.
2. Highlight "You will want to copy me."
3. Choose Edit > Copy from the menu.

Find and Replace


These functions help you locate and replace a certain word or phrase in your document. To use
these options, click on the Edit tab and click on Find or Replace. The difference between
these is that the Find command will do just that; it will locate the word(s) you are looking for,
but thats all. The Replace command will ask for the word or phrase you wish to change, along
with the word or phrase you would like to use instead. When you use either of these commands,
Word will locate every instance of the word or phrase in question, not just the first one.

Font Size
In Microsoft Word, you can change the size of your font (text). The following exercise
illustrates changing the font size.

Change Font Size - Using the Menu


1. Type the following:
I am the smallest. I am a little bigger. I am the biggest.
2. Highlight "I am the smallest."
3. Choose Format > Font from the menu.
4. Choose the Font tab.
5. Type 8 in the Size field, or click 8 in the box below the Size field.
6. Click OK.
7. Highlight "I am a little bigger."
8. Choose Format > Font from the menu.
9. Choose the Font tab.
10. Type 14 in the Size field, or click 14 in the box below the Size field.
11. Click OK.
12. Highlight "I am the biggest."
Department of Applied Science

Page 17 of 58
13. Choose Format > Font from the menu.
14. Choose the Font tab.
15. Type 24 in the Size field, or click 24 in the box below the Size field.
16. Click OK.
17. Your text should now look similar to the following:
"I am the smallest. I am a little bigger. I am the biggest."

Undo and Redo


In order to undo an action, go to Edit > Undo. To redo an action, go to Edit > Redo. It is
important to note that not all actions are undoable, thus it is important to save before you
make any major changes in your document so you can revert back to your saved document.

Common Shortcuts
These are some common shortcuts that you can use on your keyboard in almost any
Microsoft Office program:
Copy: CTRL + C
Align Left: CTRL + L
Bold: CTRL + B
Spell Check: F7
Select All: CTRL + A
Cut: CTRL + X
Align Right: CTRL + R
Italic: CTRL + I
Thesaurus: SHIFT + F7
Undo: CTRL + Z
Paste: CTRL + V
Align Center: CTRL + E
Underline: CTRL + U
Find: CTRL + F
Save: CTRL + S
Help: SHIFT + F1
Department of Applied Science

Page 18 of 58
Redo: CTRL + Y

Other helpful functions


Insert option
To insert a table:
Click on the Table button in the toolbar, or click on the Table tab at the top of the screen,
then click Insert, and Table.
You will have to specify the number of columns and rows, and then click OK.

To add rows or columns in a table:


Click on a cell where you would like to insert a row or column.
Click on the Borders and Tables button.
In the toolbar that comes up, click on the word Table
Click on one of the Insert Rows/Insert Columns choices that appear.

To delete rows or columns:


Click on a cell in the row or column you would like to delete.
Click on the Borders and Tables button.
In the toolbar that comes up, click on the word Table
Click on either Delete Rows or Delete Columns.

Inserting Symbols:
To insert a symbol that isnt on the keyboard (for example, , , 8, ., , etc.), click on the Insert
tab, and then click on Symbol. You can choose which symbol you would like to use, then
click on the Insert button when that symbol is highlighted. Click on the Close button to return
to your document.

Department of Applied Science

Page 19 of 58

Spell Check
Word checks your spelling and grammar as you type. Spelling errors display with a red wavy
line under the word. Grammar errors display with a green wavy line under the error. If you
want to spell check your entire document, press F7 and click the spelling icon
, or choose
Tools > Spelling and Grammar from the menu. If you want to spell check part of your
document, highlight the area you want to spell check. Then press F7 and click the spelling icon
, or choose Tools > Spelling and Grammar from the menu.

Headers and Footers

Headers and Footers can be used to give a uniform look to the pages of your document. To
create one, go to View > Header and Footer. Use the Header and Footer toolbar to insert
and format words and objects in the header. To move between the header and footer, use the
Switch between Header and Footer button. Click Close to exit the header or footer.

Using the Header and Footer toolbar.


Mail Merge
Department of Applied Science

Page 20 of 58
Mail merge enables you to create form letters, mailing labels, envelopes, or catalogs. There are
two files needed for a mail merge. The data source contains the data that varies in the merged
documents for example, the name and address of each recipient of a form letter. The data
source can be an existing spreadsheet, database, or text file, or a Word table that you create.
The main document contains the generic information that you want to repeat in each form
letter, mailing label, envelope, or catalog.
In the main document, merge fields (name, address, city, state, zip) are the
placeholders that tell Microsoft Word where to insert data from the data source. Merge fields
are identified by the guillemots ( ) around each field. When you execute the merge
command, Word automatically generates letters by replacing the merge fields in the main
document with the appropriate data from the source document. Each row (or record) in the data
source produces an individual form letter, mailing label, envelope, or catalog item. The idea of
a mail merge is to save you time and keystrokes; therefore, type as much information in the
main document as possible. For instance, if one of your merge fields will be a price (i.e.
$14.00), type the dollar sign in the main document so you wont have to type it for every price
in the source document.

Create a Mail Merge


The Main Document
1. Begin with a new document or you can also use an existing document.
2. Go to Tools Mail Merge The Mail Merge Helper will open.
3. Select Create. Under Main document and choose the type of document you wish to create.
4. Word will ask if you wish to use the active window as your document or create a new
document. If you began with a blank or existing document, choose Active Window. The active
document becomes the main document. A new document is created and the Mail Merge tool
bar will appear.

Department of Applied Science

Page 21 of 58

The Data Source


1. Click Mail Merge Helper on the Mail Merge toolbar.
2. Click Get Data. under Data source .
3. Choose one of the following:
Use this method if you dont already have the data stored in another
data source.
Select a Microsoft Word document, or a worksheet, database, or
other list, and then click Open. Click Edit Main Document.
Uses addresses from an electronic address book. Select an address
book, and then click OK . Click Edit Main Document

Basic Buttons & Features


Here are the functions of the basic buttons in the most commonly-used toolbars in most
Microsoft programs:

Department of Applied Science

Page 22 of 58

Department of Applied Science

Page 23 of 58

Conclusion: Students are made familiar with the basics of MS Word and how to use them
on all the commands in this part of application software.

Department of Applied Science

Page 24 of 58

Experiment 3
Title:

Practice with MS Excel, Operating and closing spreadsheets, Preparation of


spreadsheets, familiarization with various tools- formating cells, applying formulas cells.

Objective: To understand the Excel in depth like creating, editing, formatting and printing
the spreadsheets , formating cells, applying formulas cells.

S/W Requirements: MS-Office (MS-Excel)


H/W Requirements: Keyboard, Mouse, Monitor.

Introduction to MS-Excel
Start Excel 2007 from the Start Menu

Click on the Start button, point to All Programs then Microsoft Office and click on
Microsoft Office Excel 2007.

Department of Applied Science

Page 25 of 58

The first screen that you will see a new blank worksheet that contains grid of cells. This grid
is the most important part of the Excel window. It's where you'll perform all your work, such
as entering data, writing formulas, and reviewing the results.

Department of Applied Science

Page 26 of 58

Microsoft Excel 2007 Workbook and Worksheet

A worksheet is the grid of cells where you can type the data. The grid divides your worksheet
into rows and columns.

Columns are identified with letters (A, B, C ), while rows are identified with numbers (1,
2, 3 ).

A cell is identified by column and row. For example, B8 is the address of a cell in column B
(the second column), and row 8 (the eighth row).

A worksheet in Excel 2007 consists of 16,384 columns and over 1 million rows. The
worksheets in turn are grouped together into a workbook.

By default each workbook in Excel 2007 contains 3 blank worksheets, which are identified
by tabs displaying along the bottom of your screen. By default the first worksheet is called
Sheet1, the next is Sheet2 and so on as shown here.

Tools to be used in Excel:

Department of Applied Science

Page 27 of 58

Office button: When clicked, this button opens the Office menu, from which you can open,
save, print, and exit as well as the Excel Options button that enables you to change Excel's
default settings.

Quick Access Toolbar: A small toolbar next to the Office button contains shortcuts for some
of the most common commands such as Save, Undo, and Redo buttons. You also can
customize quick access toolbar.

Ribbon: A combination of old versions menu bar and toolbar, arranged into a series of tabs
ranging from Home through View. Each tab contains buttons, lists, and commands.

Name box: Displays the address of the current active cell where you work in the worksheet.

Formula bar: Displays the address of the active cell on the left edge, and it also shows you
the current cell's contents.

Worksheet area: This area contains all the cells of the current worksheet identified by
column headings, using letters along the top, and row headings, using numbers along the left
edge with tabs for selecting new worksheets.

Sheet tabs: Excel 2007 contains 3 blank worksheet tabs by default. Click on the intended tab
will go to the particular worksheet.

Status bar: Reports information about the worksheet and provides shortcuts for changing the
view and the zoom.

Zoom control: Use to zoom the Excel screen in or out by dragging the slider.

Department of Applied Science

Page 28 of 58

Excel 2007 ribbon discover the new ribbon elements in excel


The Excel 2007 Ribbona new outlook that replaces the previous versions menu bar and
drop down menus.
Yes, Excel 2007's user interface is based on the ribbon, which is a bar across the top of the
window that contains tabbed pages of commands and icons/buttons.
With the Ribbon, it shows you all the most commonly used options needed to perform a
particular Excel task and you just click on it to take action.

Here are some important terms related to Excel 2007 ribbon:

Ribbon: The whole bar, including all of the tabs.

Office Button: On the far left side of the Ribbon, the Office Button lets you perform tasks
that are common across many Office applications.

Quick Access Toolbar: Located on top of the Excel screen beside the Office Button.

Tab: Excel's main tasks are brought together and display all the commands commonly
needed. Clicking a tab name once activates the tab.

Group: A section of a tab that organizes related command buttons into subtasks. For
example, the Home tab has the following groups: Clipboard, Font, Alignment, Number,
Styles, Cells, and Editing.

Dialog box launcher: A small icon in the bottom-right corner of a group, from which you
can open a dialog box related to that group.

To understand tabs on the Excel ribbon

Home: Use this tab when creating, formatting, and editing a spreadsheet.

Insert: Use this tab when adding particular elements (including graphics, PivotTables, charts,
hyperlinks, and headers and footers) to a spreadsheet.

Page Layout: Use this tab when preparing a spreadsheet for printing or reordering graphics
on the sheet.
Department of Applied Science

Page 29 of 58

Formulas: Use this tab when adding formulas and functions to a spreadsheet or checking a
worksheet for formula errors.

Data: Use this tab when importing, querying, outlining, and subtotaling the data placed into
a worksheet's data list.

Review: Use this tab when proofing, protecting, and marking up a spreadsheet for review by
others.

View: Use this tab when changing the display of the Worksheet area and the data it contains.

To enter text into a worksheet

Select the cell in which you want to enter the text.

Type in the text/data into the cell.

Press the Enter key. Text entries are left aligned by default.

To enter numbers into a worksheet

Select the cell in which you want to enter a number.

Type in the number into the cell and press Enter.

If you want to enter a negative number, type a minus sign in front of it or enclose it in
parentheses (bracket), e.g. -15 or (15).

To indicate decimal places, you type a full stop such as 125.89.

The numbers will be right aligned by default.

To enter dates and times into a worksheet

Select the cell in which you want to enter the date or time.

Type in the date or time. Separate the date with either hyphens (-) or slashes (/).

Press Enter.

To enter the current date, press Ctrl+;

To enter the current time, press Ctrl+:

To speed up your data entry

Enter key: Pressing the key will enters the data and moves the active cell highlight down
to the next cell in the current column.

Tab key: Pressing the key will enters the data and moves the active cell highlight to the next
cell in the current row.

Arrow keys: Pressing the key will enters the data and moves the active cell highlight to the
next cell in the direction of the specific arrow key pressed.
Department of Applied Science

Page 30 of 58

Esc key: Pressing the key will cancels the current data entry.

Save A Sheet:
To save a workbook (first time)

From Office Button, click Save OR .Click the Save button on the Quick Access Toolbar.

From the Save As dialog box displayed, ensure that you browse to the folder/disk drive that
you would like to save the file.

Enter the file name in the File name: text box. The file name can be up to 255 characters in
length.

Click on the Save button.

To close a file:

From the Office Button, click Close.

You will be asked if you wish to save any changes you have made to the file.
Department of Applied Science

Page 31 of 58

Click Yes to save the workbook


OR click No to ignore (without saving) the changes
OR click Cancel to cancel the operation

To conclude, you have two choices for saving a spreadsheet file:

Save As - this choice allows you to save your spreadsheet file with a new name and choose
the location to save the file.

Save - this option updates the spreadsheet file with your most recent changes. If you use Save
on a new file that hasn't been saved before, it has the same effect as Save As.
Conclusion: Students are made aware of the working of MS Excel and all the types of data
processing commands

Department of Applied Science

Page 32 of 58

Experiment 4
Title: Practice with MS Power Point, Opening and closing slides, Preparation of slides,
familiarization with various tools- applying design, themes, animation on slides.

Objective: To understand the PowerPoint in depth like creating, editing and formatting
slides, also applying design, themes, animation on slides.

S/W Requirements: MS-Office (MS-PowerPoint)


H/W Requirements: Keyboard, Mouse, Monitor.

Theory:
Introduction to MS-PowerPoint
To start PowerPoint 2007 from the Start Menu

Click on the Start button, point to All Programs then Microsoft Office and click on
Microsoft Office PowerPoint 2007.

The first screen that you will see a new blank presentation begins automatically with one
slide.

From this first slide, you can see the Microsoft PowerPoint 2007 environment consists of the
following elements:

When you click the Office Button, commands related to managing PowerPoint and
PowerPoint presentations are gathered together on this menu.

The Title bar displays the name of the active presentation. At the right end of the title bar
are the three familiar buttons - Minimize, Restore and Close buttons.

Below the title bar is the Ribbon, which makes all the capabilities of PowerPoint available
in a single area so that you can work efficiently with the program. You can find more
descriptions about the PowerPoint 2007 ribbon.

Across the bottom of the program window, the Status bar gives you information about the
current presentation.

At the right end of the status bar is the View toolbar, which provides tools for adjusting the
view of presentation content.

Discover The Power point 2007 Screen Elements and It Function


Department of Applied Science

Page 33 of 58
Once you want to start learning the PowerPoint 2007, it's important to know the PowerPoint
2007 Screen Elements as well as its functions.

Office button: Opens the Office menu, from which you can open, save, print, and start new
presentations.

Quick Access Toolbar: A small toolbar next to the Office button contains shortcuts for some
of the most common commands.

Title bar: Identifies the PowerPoint program running and the name of the active presentation.

Minimize button: Shrinks the application window to a bar on the taskbar; you click its button
on the taskbar to reopen it.

Maximize/Restore button: If the window is maximized (full screen), click will changes it
to windowed (not full screen) and vice versa.

Close button: Closes the application.

Ribbon: Functions as a combination of menu bar and toolbar, offering tabbed "pages" of
buttons, lists, and commands.

Presentation window: Where active PowerPoint slide(s) appear where you work on the
slide.

Status bar: Reports information about the presentation and provides shortcuts for changing
the view and the zoom.

Adding New slide in power point 2007

Department of Applied Science

Page 34 of 58
Slide is the foundation of a presentation. To create a presentation, you need to add new slide
to your presentation.
A slide layout contains placeholders, such as text, chart, table, or Smart Art graphic, where you
can enter text or insert elements.
When you create a new slide, you can apply a standard layout or a custom layout of your own
design. You can also apply a layout to an existing slide at any time.

To create a new presentation

Open PowerPoint 2007.

Click the Office Button, then click New.

From the New Presentation dialog box displayed, select Blank Presentation.

Click Create button.

To enter title and subtitle

Click on "Click to add title" section of the slide and enter the slide title.

Click on "Click to add subtitle" section of the slide and enter the desired text.

To insert a new slide with different layouts

On the Home tab, in the Slides group, click the lower portion of the New Slide button. This
will displayed several layouts:

Click on the intended layout will insert the slide to your presentation.

How To Copy Slides From Other Power Point Presentation


Department of Applied Science

Page 35 of 58
There are several ways to copy slides from other presentations. These included:

Open two PowerPoint windows side-by-side and drag-and-drop slides between them.

Open two PowerPoint presentations, copy slides from one of them to the Clipboard (Ctrl+C),
and then paste them into the other presentation (Ctrl+V).

Use the PowerPoint Reuse Slides feature, as described here.

Save a Presentation and backup copy


To save a presentation, you can either save in your computer hard drive or other device
such as diskette or handy/flash drive.

To save a presentation (first time)

From Office button, click Save OR Click the Save button on the Quick Access Toolbar.

From the Save As dialog box displayed, ensure that you browse to the folder/disk drive that
you would like to save the file.

Enter the file name in the File name: text box. The file name can be up to 255 characters in
length.

Click on the Save button.


Conclusion: Student is made familiar with the features of Power Point and creates
presentations using various affects and animations.

Department of Applied Science

Page 36 of 58

Experiment 5
Title: Write a program to print a message on screen using escape sequence.
Objective: To understand basics of C programming and basic input/output functions such
as printf() and scanf().

S/W Requirements: Turbo C


H/W Requirements: Keyboard, Mouse, Monitor.
Theory:
#include<stdio.h>
#include<conio.h>
void main()
{
clrscr();
printf("\t\tThis is a C program");
getch();
}
Output:

Conclusion: Students are taught to implement the basics of C programming and make use of
input output functions.

Department of Applied Science

Page 37 of 58

Experiment 6
Title: Programs based on conditional statements.
Objective: To study various conditional control statements and implement them in different
programs.

S/W Requirements: Turbo C


H/W Requirements: Keyboard, Mouse, Monitor.
Theory: There are different types of conditional control statements such as simple if, ifelse, nested if else, if else if ladder and switch case construct.
6.1 Program to find that given number is even or odd.

#include<stdio.h>
#include<conio.h>
void main()
{
int number;
clrscr();
printf("Enter any number\n");
scanf("\n%d",&number);
if(number%2==0)
printf("\n%d is Even Number");
else
printf("\n%d is Odd Number");
getch();
}
OUTPUT:

Department of Applied Science

Page 38 of 58

6.2 Programs to find the greatest among 3 numbers using if else statement.

#include<stdio.h>
#include<conio.h>
void main()
{
int a,b,c,big;
clrscr();
printf("Enter First Number\n");
scanf("%d",&a);
printf("Enter Second Number\n");
scanf("%d",&b);
printf("Enter Third Number\n");
scanf("%d",&c);
if(a>=b && a>=c)
printf("%d is greatest",a);
else if(b>=a && b>=c)
printf("%d is greatest",b);
else
printf("%d is greatest",c);

getch();
}
OUTPUT:

Department of Applied Science

Page 39 of 58
6.3 Program to add, subtract, multiply, divide using switch statement.
#include<stdio.h>
#include<conio.h>
void main()
{
char ch;
int a,b,c;
clrscr();
printf("Enter the value of First Operand");
scanf("%d",&a);
printf("Enter the value of Second Operand");
scanf("%d",&b);
printf("Enter the Choice");
scanf("%c",&ch);
printf("\n entered choice is %c",ch);
switch(ch)
{
case 'A':
c=a+b;
printf("Result after Addition of %d and %d numbers is:%d",a,b,c);
break;
default:
printf("wrong");
getch();
}
}
OUTPUT:

Conclusion: Students are made aware to implement decision logic using C programming
conditional statements in different programs.

Department of Applied Science

Page 40 of 58

Experiment 7
Title: Programs based on looping statements.
Objective: To understand various looping statements and implement them in a number of
programs.

S/W Requirements: Turbo C


H/W Requirements: Keyboard, Mouse, Monitor.
Theory: There are three looping statements such as for loop, while loop and do while loop.
7.1 Program to print pyramid for different patterns using for loop.
#include<stdio.h>
#include<conio.h>
void main()
{
int i,j,n,k,n1=0;
clrscr();
printf("Enter the value of rows");
scanf("%d",&n);
for(i=n;i>=1;i--)
{ n1=n1+1;
printf("\n");
for(j=1;j<=i;j++)
{
printf(" ");
}
for(k=1;k<=n1;k++)
{
printf("* ");
}
}
printf("\n \n");
for(i=1;i<=n;i++)
{
printf("\n");
for(j=1;j<=i;j++)
{
printf("*");
}
}
//printf("\n \n");
n1=0;
for(i=n;i>=1;i--)
{
n1++;
printf("\n");
for(j=1;j<=i;j++)
Department of Applied Science

Page 41 of 58
{
printf(" ");
}
for(k=1;k<=n1;k++)
{
printf("*");
}
}
getch();
}
OUTPUT:

7.2 Program to print the table of a given number using while/ do while loop.
a)

Using While Loop

#include<iostream.h>
#include<conio.h>
void main()
{
int number, counter=1,ans;
clrscr();
printf("Enter a number whose Table is to be printed");
scanf("%d",&number);
while(counter<=10)
{
ans=number*counter;
Department of Applied Science

Page 42 of 58
printf("%d * %d = %d",number,counter,ans) ;
counter++;
}
getch();
}
b) Using Do While Loop
#include<stdio.h>
#include<conio.h>
void main()
{
int number,counter=1,ans;
clrscr();
printf("Enter a number whose Table is to be printed");
scanf("%d",&number);
do
{
ans=number*counter;
printf("\n
%d * %d = %d",number,counter,ans) ;
counter++;
} while(counter<=10);
getch();
}

OUTPUT:

Department of Applied Science

Page 43 of 58
7.3 Program to print the factorial of a number.
#include<stdio.h>
#include<conio.h>
void main()
{
int number, i;
long fact=1;
clrscr();
printf("Enter the Number whose Factorial is to be find");
scanf("%d",&number);
if(number==0)
{
fact=0;
}
else
for(i=1;i<=number;i++)
{
fact=fact*i;
}
printf("The Factorial of a Number %d is %ld ",number,fact);
getch();
}
OUTPUT:

Conclusion: Students are made aware to implement iterative logic using C programming
looping statements in a number of programs.

Department of Applied Science

Page 44 of 58

Experiment 8
Title: Programs based on functions.
Objective: To understand the user defined functions and create user defined functions for
different programs.

S/W Requirements: Turbo C


H/W Requirements: Keyboard, Mouse, Monitor.
Theory: 8.1 Program to swap two numbers using a) call by value b) call by reference.
a)

Call by Value

#include<stdio.h>
#include<conio.h>
void swapv(int,int);
void main()
{
int a,b;
clrscr();
printf("Enter The Values of A and B");
scanf("%d %d",&a,&b);
printf("THE VALUES BEFORE SWAPPING IS ");
printf("\n A=%d B=%d",a,b);
swapv(a,b);
getch();
}
void swapv(int x,int y)
{
int temp;
temp=x;
x=y;
y=temp;
printf("\n THE VALUES AFTER SWAAPING IS ");
printf("\n A=%d B=%d",x,y);
}
OUTPUT:

Department of Applied Science

Page 45 of 58

b)

Call by Reference

#include<stdio.h>
#include<conio.h>
void swapr(int*,int*);
void main()
{
int a,b;
clrscr();
printf("Enter The Values of A and B");
scanf("%d %d",&a,&b);
printf("THE VALUES BEFORE SWAPPING IS ");
printf("\n A=%d B=%d",a,b);
swapr(&a,&b);
printf("\n THE VALUES AFTER SWAPPING IS ");
printf("\n A=%d B=%d",a,b);
getch();
}
void swapr(int *x,int *y)
{
int temp;
temp=*x;
*x=*y;
*y=temp;
}
OUTPUT:

Department of Applied Science

Page 46 of 58

8.2 Program to print the sum of first n natural numbers by using recursion.
#include<stdio.h>
#include<conio.h>
int add(int n);
void main()
{
int n;
printf("enter a positive no");
scanf("%d",&n);
printf("sum=%d",add(n));
getch();
}
int add(int n)
{
if(n!=0)
return n+add(n-1);
}

Conclusion: Students are made aware of the functions and call functions using call by value
and call by reference concepts.

Department of Applied Science

Page 47 of 58

Experiment 9
Title: Programs based on Arrays.
Objective: To understand the derived data types such as arrays and implement one
dimensional and multi dimensional arrays in different programs.

S/W Requirements: Turbo C


H/W Requirements: Keyboard, Mouse, Monitor.
Theory: 9.1 Program to display the biggest value in an integer array.
#include<stdio.h>
#include<conio.h>
void main()
{
int a[10],i,big,n;
clrscr();
printf("Enter The Size Of Array \n");
scanf("%d",&n);
printf("\n Enter the Elements of Array");
for(i=0;i<n;i++)
{
printf("\n Enter the %d Element",i);
scanf("%d",&a[i]);
}
big=a[0];
for(i=1;i<n;i++)
{
if(a[i]>big)
{
big=a[i];
}
}
printf("\n Greatest Element Of Array is %d",big);
getch();
}
OUTPUT:

Department of Applied Science

Page 48 of 58

9.2 To multiply two matrices using arrays.


#include<stdio.h>
#include<conio.h>
void main()
{
int a[5][5],b[5][5],c[5][5],i,j,k,r1,c1,r2,c2;
clrscr();
printf("Enter the Rows and Coloumns of First Matrix\n");
scanf("%d%d",&r1,&c1);
printf("\nEnter the Rows and Coloumns of Second Matrix");
scanf("%d%d",&r2,&c2);
if(r2==c1)
{
printf("\nEnter The Elements Of First Matrix");
for(i=0;i<r1;i++)
{
for(j=0;j<c1;j++)
{
scanf("%d",&a[i][j]);
}
}
printf("\nEnter The Elements of Second Matrix");
for(i=0;i<r2;i++)
{
for(j=0;j<c2;j++)
Department of Applied Science

Page 49 of 58
{
scanf("%d",&b[i][j]);
}
}
printf("\nFirst Matrix is");
for(i=0;i<r1;i++)
{
printf("\n");
for(j=0;j<c1;j++)
{
printf("%d\t",a[i][j]);
}
}
printf("\nSecond Matrix is");
for(i=0;i<r2;i++)
{
printf("\n");
for(j=0;j<c2;j++)
{
printf("%d\t",b[i][j]);
}
}
for(i=0;i<r1;i++)
{
for(j=0;j<c2;j++)
{
c[i][j]=0;
for(k=0;k<c1;k++)
{
c[i][j]=c[i][j]+a[i][k]*b[k][j];
}
}
}
printf("\nResult of Matrix Multiplication is");
for(i=0;i<r2;i++)
{
printf("\n");
for(j=0;j<c2;j++)
{
printf("%d\t",c[i][j]);
}
Department of Applied Science

Page 50 of 58
}
}
else
{
printf("Matrix Multiplication is Not Possible");
}
getch();
}

OUTPUT:

Conclusion: Students are made aware about arrays and perform various operations on
arrays.

Department of Applied Science

Page 51 of 58

Experiment 10
Title: Programs based on strings.
Objective: To understand the use and implementation of strings using characters arrays and
implement various built in string manipulation functions.

S/W Requirements: Turbo C


H/W Requirements: Keyboard, Mouse, Monitor.
Theory: 10.1 Program to concatenate two strings & store the result in third string.
#include<stdio.h>
#include<conio.h>
#include<string.h>
void main()
{
char str1[50], str2[50], str3[50];
clrscr();
printf("Enter first string");
scanf("%s", str1);
printf("Enter second string");
scanf("%s", str2);
printf(" Result: %s", strcat(str1, str2));
getch();
}
OUTPUT:

Department of Applied Science

Page 52 of 58
10.2 Program to check whether the string is palindrome.
a) Without using string inbuilt functions
#include<stdio.h>
#include<conio.h>
#include<string.h>
void main()
{
char str1[50];
int i=0,j=0,len=0,flag=1;
clrscr();
printf("Enter the String");
scanf("%s",&str1);
printf("\n String is:%s",str1);
while(str1[i]!= '\0')
{
len=len+1;
i++;
}
for(i=0,j=(len-1);i<(len/2);i++,j--)
{
if(str1[j]!=str1[i])
{
flag=0;
break;
}
}
if(flag==1)
{
printf("\n String is Palindrome");
}
else
{
printf("\n String is not Palindrome");
}
getch();
}
b) With using string inbuilt functions.
#include<stdio.h>
#include<conio.h>
Department of Applied Science

Page 53 of 58
#include<string.h>
void main()
{
char str1[50], str2[50];
int i;
clrscr();
printf("Enter string");
scanf("%s", &str1);
strcpy(str2, str1);
strrev(str1);
i=strcmp(str1, str2);
if(i==0)
{
printf("\nInput string is palindrome");
}
else
{
printf("\nInput string is not palindrome");
}
getch();
}
OUTPUT:

Conclusion: Students are made aware of the concept of strings and use string manipulation
functions.

Department of Applied Science

Page 54 of 58

Experiment 11
Title: Programs based on structures and unions.
Objective: To understand user defined data types and create user defined data types using
structures and unions.

S/W Requirements: Turbo C


H/W Requirements: Keyboard, Mouse, Monitor.
Theory: 11.1 Program to read & print the record of 5 students using structures.
#include<stdio.h>
#include<conio.h>
struct Student
{
char Name[20],Class[10];
int RollNo;
};
void main()
{
struct Student s1[5];
int i;
clrscr();
for(i=1;i<=5;i++)
{
printf("\n Enter the Name of %d Student",i);
scanf("%s",&s1[i].Name);
printf("\n Enter the Class %d Student",i);
scanf("%s",&s1[i].Class);
printf("\n Enter the Roll No of %d Student",i);
scanf("%d",&s1[i].RollNo);
}
printf("\n Entered Data is");
printf("\nName\t\tClass\tRollNo");
for(i=1;i<=5;i++)
{
printf("\n%s\t\t%s\t%d",s1[i].Name,s1[i].Class,s1[i].RollNo);
}
getch();
}

Department of Applied Science

Page 55 of 58
OUTPUT:

11.2 Program to implement the concept of union.


#include <stdio.h>
union job {
char name[32];
float salary;
int worker_no;
}u;
int main(){
printf("Enter name:\n");
scanf("%s",&u.name);
printf("Enter salary: \n");
scanf("%f",&u.salary);
printf("Displaying\nName :%s\n",u.name);
printf("Salary: %.1f",u.salary);
return 0;
}

Department of Applied Science

Page 56 of 58

Conclusion: Students are taught to create user defined data types using structures and unions
and use them in programs.

Department of Applied Science

Page 57 of 58

Experiment 12
Title: Programs based on files.
Objective: To understand the concept of files and perform various file operations using C
programs.

S/W Requirements: Turbo C


H/W Requirements: Keyboard, Mouse, Monitor.
Theory: Program to copy the contents of one file to another file.
#include<stdio.h>
#include<conio.h>
void main()
{
FILE *fs, *ft;
char ch;
fs=fopen("Struct.c","r");
if(fs==NULL)
{
puts("cannot open source file");
}
ft=fopen("File.c","w");
if(ft==NULL)
{
puts("cannot open target file");
}
while(1)
{
ch=fgetc(fs);
if(ch==EOF)
{
break;
}
else
{
fputc(ch,ft);
}
}
print(File Copied Sucessfully);
fclose(fs);
fclose(ft);
getch();
}
Output:
Department of Applied Science

Page 58 of 58

Conclusion: Students are taught to implement various file related concepts using various
file manipulation functions.

Department of Applied Science

Potrebbero piacerti anche