top astronomy and space articles

[astronomy][bleft]

interesting blogs

[interesting][bleft]

ALGORITHMS, PSEUDO CODE, and FLOWCHARTS??? • LEVEL::BEGINNER

When you are studying anything related to computer coding and some of that stuff, you might have heard these harsh looking words which seen to be difficult to understand and even to pronounce. Yes, the words are PSEUDO code, Algorithms and Flowcharts.

So what are these creepy looking words because it is the first thing you want to know due to the fact that it will be a very important topic in your examinations, in fact it is kinda an important thing to know first before you start coding. But lets keep all these things apart and discuss the point, these terminologies aren't difficult to understand and will help you in coding your program, like you read previously - like a lot!

You want to first to make a logic to solve a problem, that's where these creepy words will start helping you. Find out about them by reading down below.

Algorithms

Algorithms is the most informal step, hence, informal High Level language understandable for humans only. Such codes can be defined by the natural language steps just like defining recipe of a food item. Such steps do not contain any technical way of explaining a thing but rather it enable us to think of solving a problem in our natural language and draw out steps in which a problem can be resolved. PSEUDO code is next step after Algorithm is written.

Let's take an example, shall we? Suppose you have to add two numbers and get an average of their output. So how you will write an algorithm to solve this problem? Take a look:

Step 1: Enter two numbers
Step 2: Add the numbers
Step 3: Divide the result by two
Step 4: Get the result on screen

So what do you know; it's simple English language, isn't it? Well this is the actual algorithm programmers write to solve a problem.

PSEUDO code

It is the informal High Level language which means it is only intended for human understandings and such programs cannot run and execute in computers. PSEUDO code are a type of Algorithms but they contain some technical steps in order to make such steps written in simple language more understandable and logical only for human beings. Flowcharts are also an alternative to PSEUDO codes.

So again, how are you gonna solve the same problem as described above? Let's find out:

Step 1: Input two numbers
Step 2: number 1 + number 2, save it in result
Step 3: result/2, save it in average
Step 4: Print the average

Kinda, it is the same thing with some technical usage like input, plus sign (+), division sign (/), print in this example.

Flowcharts

This is the simplest way to solve a problem and yes, it is the most recommended option; if not from others but it is definitely from us. Hey, it works for us! Flowcharts are the simplest thing ever because it has some fancy looking graphical symbols, which you gotta believe us, it is sooo good. The picture down below will show you all the symbols required when writing, we mean drawing, a solution to a problem.
Symbols of flowcharts with its meaning

So now you know the symbols, let's solve our problem with some of the above symbols. We require a Terminator to start our program, after that you require a Manual Input symbol to give inputs, then Process symbol for adding, again a Process symbol for finding out the average, then use the Display symbol to print on screen. After all these, you place a Terminator symbol in the end to stop the program. That's it, you are done. How it looks like? Well look down below:

Above problem solving by Flowchart
Finding the average of two numbers by Flowchart

This is how you do it! 

We hope that you learnt something from us and if you really did please comment down below and share it with your friends. Thank you for reading, we appreciate it!

Zain Ul Mustafa

Cakes, conspiracies, and computers are my daily pills.

Post A Comment
  • Blogger Comment using Blogger
  • Facebook Comment using Facebook
  • Disqus Comment using Disqus

No comments :