Subroutine and functions, Basic Computer Science

Assignment Help:

Subroutine and Functions:

 In a program, it is often necessary to repeat a statement or group of statements at several points to accomplish a particular task. Repeating the same statement in a program each time makes a program lengthy and reduces readability. These problems could be sorted out if the necessary statements could be written once and then referred to each time they are needed. This is the purpose of a subprogram. Basically there are two different types of subprograms, called functions and subroutines.  Making subprograms allows tackling small pieces of a problem individually. 

Once each piece is working correctly then the pieces are integrated together to create the complete solution of the problem. To implement functions and subroutines, we require writing the main program that references all of the subprograms in the desired order and also writing the subprograms. This can  be done in any order that is convenient. 


Related Discussions:- Subroutine and functions

In-door patient department, In-door Patient Department Ideally all ...

In-door Patient Department Ideally all features of OPD.  Both OPD and IPD modules should be inter-linked.  In addition all details pertaining to the patient's medica

Two dimensional arrays, Two dimensional Arrays:  A two-dimensional array ...

Two dimensional Arrays:  A two-dimensional array is like a table, with a defined number of rows, where each row has a defined number of columns. In some instances we need to  hav

Why is the random class in the .net framework not suitable, QUESTION (a...

QUESTION (a) (i) Why is the Random class in the .NET framework not suitable for generating random bytes for cryptography purposes? (ii) Mention two characteristics required

Audio/video applications on network, AUDIO/VIDEO APPLICATIONS ON NETWORK ...

AUDIO/VIDEO APPLICATIONS ON NETWORK Clinical applications of a computer include recording of slit lamp images on a computer. These still images or even videos can be recorde

Data type, Data Type:  Data Type: Anything that is processed by a comp...

Data Type:  Data Type: Anything that is processed by a computer is called data. There are different types of data that can be given to the computer for processing. A  data typ

Networking.., write advantages and disadvantages of private and public netw...

write advantages and disadvantages of private and public network

Advantages of computerized record-keeping, Advantages of Computerized Reco...

Advantages of Computerized Record-keeping Less manpower is required for upkeep.  Recording, storing, and retrieving are all much faster: easier and with little practice

Difference between an html and an xhtml page, QUESTION (a) Define four ...

QUESTION (a) Define four special target names use with the TARGET attribute (b) Explain the main difference between an HTML and an XHTML page (c) Give two merits and two

Project on ASP .NET MVC 5, I am looking for a project which is based on ASP...

I am looking for a project which is based on ASP.NET MVC 5.Could you please help me ?

Definition of ALU , The ALU, or the arithmetic and logic unit is the part...

The ALU, or the arithmetic and logic unit is the part of the processor that is occupied with executing operations of an arithmetic or logical nature. It works in conjunction by mea

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd