Unit 7: Computational Thinking — Short Questions
9th Class Computer Science · Unit 7: Computational Thinking
Computational Thinking
Computational Thinking (CT) is a problem-solving process that involves a set of skills and techniques to solve complex problems in a way that a can be executed by a computer. This approach can be used in various fields beyond computer science, such as biology, mathematics, and even daily life.
Computational Thinking (CT) is a problem-solving process that involves a set of skills and techniques to solve complex problems in a way that a can be executed by a computer. This approach can be used in various fields beyond computer science, such as biology, mathematics, and even daily life.
Yes, Computational thinking is not limited to computer science. It is used in everyday problem solving, such as planning a trip or organizing tasks.
Flowchart
Flowchart is a diagrammatic representation of an algorithm. It describes what operations are required to solve a given problem. Flowchart illustrates the sequence of operations to be performed to solve a problem in the form of a diagram.
The flowchart developer must determine the following requirements for the given problem or algorithm before drawing a flowchart.
- Start of the flowchart
- Input to the flowchart
- Type of processing required
- Decision to be taken
- Output of the operation
- End of the flowchart
For flowchart designing, different software tools are available to design the flowcharts. Some of the famous tools are Microsoft Visio and LARP software.
- Microsoft Visio
- LARP (Logics of Algorithms and Resolution of Problems)
Following steps will be followed while creating flowchart.
- Start Microsoft Visio
- Click on the category of Flowchart
- Double-click the Basic Flowchart
- For each step, you wish to design in the process, drag a relevant flowchart symbol and place itonto your drawing.
- Connect the flowchart shapes by holding the mouse pointer over the first symbol, and thenreleasing it on the to the other symbol you wish to connect to.
- To place text into a shape, select it, and then type.
Flowchart symbols
Symbol → | Name: Flow line | Description: This symbol shows the flow of data, information or processi the flowchart.
Symbol Oval | Name: Terminal | Description: An oval shape symbol that represents the Start and End of aflowchart.
Symbol Rectangle | Name: Process | Description: A Rectangle shape symbol is used to represent the processor action taken or shows all the calculations.
Symbol Diamond | Name: Decision | Description: A diamond represents a decision symbol used for comparison or a decision. It changes the flow of control and decides a particular path to be followed.
Symbol Parallelogram | Name: Input/output | Description: A parallelogram represents either input or output operation regardless of the input or output method.
Symbol Small circle | Name: Connector | Description: A small circle represents a connector symbol and is used to join various parts of a flow chart. Connectors are used when flow chart is very large and complex and the numbers inside them identify their links. Control is transferred from one connector to another with the same number in a program.
Flowchart to find the area of triangle
Step 1. Start
Step 2. Input B, H
Step 3. A=(B*H)/2
Step 4. Output A
Step 5. End
Properties of CT
Following are the basic properties of Computational Thinking:
- Decomposition
- Abstraction
- Pattern Recognition
- Algorithm Design
Pattern recognition involves looking for similarities or patterns among and within problems. For instance, if you notice that you always forget your homework on Mondays, you might recognize a pattern and set a reminder specifically for Sundays. Pattern recognition is an essential aspect of computational thinking.
Making a Cup of Tea - High-level Steps: 1. Boil water. 2. Add tea leaves or a tea bag. 3. Steep for a few minutes. 4. Pour into a cup and add milk/sugar if desired.
To find the sum, product and average of five given numbers.
Step 1. Start
Step 2. Input numbers, a,b,c,d,e
Step 3. Set sum to a+b+c+d+e
Step 4. Set product to a×b×c×d×e
Step 5. Set average to a + b + c + d + e / 5
Step 6. Output sum, product, average
Step 7. End
Computational thinking involves several key principles that guide the process of problem-solving in a structured manner.
- Problem Understanding
- Problem Simplification
- Solution Selection and Design
Flowchart
They are excellent tools for communicating complex processes to a wide audience, ensuring everyone has a common understanding.
Flowchart for leap year determination
Step 1. Start
Step 2. Input Year
Step 3. If year mod 4 = 0
Step 4. Print a leap year (Yes path)
Step 5. Print not a leap year (No path)
Step 6. Stop
Pseudocodes & Dry Run
Pseudocode is a method of representing an algorithm using simple and informal language that is easy to understand. It combines the structure of programming clarity with the readability of plain English, making it a useful tool for planning and explaining algorithms.
Pseudocode for determining if a number is even or odd.
1. Procedure Check Even Odd(number)
2. Input: number (The number to be checked)
3. Output: "Even" if number is even, "Odd" if number is odd
4. Begin
5. if (number % 2 = 0) then
6. print "Even"
7. else
8. print "Odd"
9. End if
10. End
Pseudocode is a method of representing an algorithm using simple and informal language that is easy to understand. It combines the structure of programming clarity with the readability of plain English, making it a useful tool for planning and explaining algorithms.
A dry run involves manually going through the algorithm with sample data to identify any errors.