0% found this document useful (0 votes)
38 views

L-032 L2 Samyuktha Mandampully PPS Experiment 1 PDF Algorithms Computer Programming 4

Uploaded by

priyanshamesara
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
38 views

L-032 L2 Samyuktha Mandampully PPS Experiment 1 PDF Algorithms Computer Programming 4

Uploaded by

priyanshamesara
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

Search

L-032 L2 Samyuktha
Mandampully PPS
Experiment 1
Uploaded by Samyuktha Jagesh

 0 ratings · 56 views · 14 pages


AI-enhanced description

Document Information 
This document contains instructions for an experi…

Original Description:
Download now

Download as pdf or txt
Copyright
© © All Rights Reserved

Available Formats SVKM’s NMIMS University


Mukesh Patel School of Technology Management & Engineering
PDF, TXT or read online from
COURSE:Scribd
Programming for Problem Solving

Share this document


SVKM’s NMIMS


Facebook

Mukesh Patel School of Technology Management and
Engineering, Vile Parle, Mumbai- 400056

Twitter


Email

Did you find this document useful?


Manual of Programming for
Problem Solving

Is this content inappropriate? Report this Document

AD Download to read ad-free

SVKM’s NMIMS University


Mukesh Patel School of Technology Management & Engineering
COURSE: Programming for Problem Solving

Experiment: 1
PART A

(PART A: TO BE REFFERED BY STUDENTS)

A.1 Aim: To study Algorithm and Flow charts

A.2 Learning Outcomes: Learner would be able to

1. Interpret the steps of algorithm into a flowchart.


2. Explain the features of each symbol of the flowchart.
3. Analysis the scenario to write algorithm and flowchart (breaking the problem into steps of
selection, sequence).

TASK: Read two numbers from the user and add these 2 numbers and store the result for
future use

TASK: perform addition of 10 numbers

Inputs /outputs/operations
Step 1: accept first number from user into variable A
Step 2: accept second number from user into variable B
Step 3: accept third number in X
Step 4: accept fourth number in Y
STEP 5: accept fifth number in V
Step 6 : accept sixth number
Step 3: Perform C = A+B
Step 4: store the addition/result into C
Step 5: stop

ITERATION: REPETATION OF STEPS {EXTRA KNOWLEDGE: How many times to be


repeated?, how will I keep track of number of repetition? What to repeat ?

Step 1: start algorithm

AD Download to read ad-free

SVKM’s NMIMS University


Mukesh Patel School of Technology Management & Engineering
COURSE: Programming for Problem Solving

Step 2: set Counter =1 and SUM =0 { initialization }


Step 3: Repeat steps 4 to 6 till Counter is not equal to 10
Step 4: read NEXT number into X
Step 5: SUM = SUM+X
STEP 6: Counter = Counter +1
Step 6: stop

Iterations:

A.3 Theory:

Algorithm:

Defined as: “A sequence of activities to be processed for getting desired output from a given input.”
+ Addition

- Subtraction

* Multiplication

/ Division

 Assignment. For example B  Y*7 means B will


have the value of Y*7

Read For taking input

Print For displaying output

Start For beginning the algorithm steps

End For stopping the algorithm steps to make it a finite


algorithm

if <condition> then <statement> else For conditional statement


<statement>

Go to step n For moving to step n

Flowchart:

AD Download to read ad-free

SVKM’s NMIMS University


Mukesh Patel School of Technology Management & Engineering
COURSE: Programming for Problem Solving

Defined as a diagram which visually presents the flow of data through processing systems.
Flowchart can be used for representing an algorithm. It describes the operations (and in what
sequence) are required to solve a given problem.

Sr.No Shape Description

1 Terminal: To represent the start and end of algorithms

2 Input/Output: To represent the input and output or the


read and write operations of algorithms.

3 Processing: To represent the processing of instructions


like arithmetic operation and data manipulators.

4 Decision: To represent branching of the statements. To


take decisions. There will be one entry point and more
than one exit point.

5 Flow Line: To represent flow of data or the sequence of


statements.

6 On-page Connector: Used to join different flowline

7 Off-page Connector: Used to connect flowchart portion


on different page.

8 Predefined Process/Function: Used to represent a


group of statements performing one processing task.

A.4 Task 1:

For the following Problem Statements write Algorithm and Draw a Flowchart.

AD Download to read ad-free

AD Download to read ad-free

AD Download to read ad-free

AD Download to read ad-free

AD Download to read ad-free

AD Download to read ad-free

AD Download to read ad-free

AD Download to read ad-free

Sponsored

You might also like