Sponsored Links


Results 1 to 2 of 2

Thread: sir i cant under stand function and cant apply it in program please help me

  1. #1
    sana.pari
    Guest

    MIXX sir i cant under stand function and cant apply it in program please help me

    Sponsored Links1



  2. #2
    Dear student!
    Functions are like sub tasks. They receive some information, do some process and provide result. Functions are invoked by calling program. Calling program calls a function by giving it some information and receives the result. This is the basic idea of a function. There are two things related to a function which are declaration and definition. Declaration is the prototype of the function, that includes the return type, name and argument list to the function and definition is the actual function code.

    For example, a function is given below

    double raiseToPow(double x ,int power)
    {
    double result;
    int i;
    result=1.0;
    for(i=1;i<=power;i++)
    { result *= x;
    }
    return(result);
    }

    This function can not be executed untill we use it in a program. We would have to write program which will use this function.
    Please consult lecture 9 for further descritpion. Try sample programs given in the lecture. Your concept will be clarified.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Virtual University Last Date to Apply for Admission & Entry Test Date for MS Program
    By education-2014 in forum Virtual University Announcenments
    Replies: 0
    Last Post: 09-29-2014, 09:25 PM
  2. Replies: 0
    Last Post: 05-31-2012, 01:46 AM
  3. Replies: 0
    Last Post: 05-31-2012, 01:40 AM
  4. Replies: 0
    Last Post: 11-05-2011, 05:03 PM
  5. Replies: 1
    Last Post: 04-24-2011, 06:26 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
-: Vuhelp Disclaimer :-
None of the files shown here are hosted or transmitted by this server. The links are provided solely by this site's users. The administrator's or staff of Vuhelp.net cannot be held responsible for what its users post, or any other actions of its users. You may not use this site to distribute or download any material when you do not have the legal rights to do so. It is your own responsibility to adhere to these terms. If you have any doubts about legality of content or you have any suspicions, feel free to contact us.
Online Education | JhelumSoft | Jobs