By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,405 Members | 1,053 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,405 IT Pros & Developers. It's quick & easy.

Functions

P: 4
I'm having trouble figuring this out...


Write the definition of a function twice , that receives an integer parameter and returns an integer that is twice the value of that parameter.
Nov 4 '06 #1
Share this Question
Share on Google+
1 Reply


Expert 100+
P: 1,510
I'm having trouble figuring this out...


Write the definition of a function twice , that receives an integer parameter and returns an integer that is twice the value of that parameter.
The function definition is where the body (code) of the function is implemented and takes the following general form:
Expand|Select|Wrap|Line Numbers
  1. result_type function_name(parameter_list)
  2. {                              
  3.    declarations and definitions 
  4.    statements                     
  5. }    
  6.  
Nov 4 '06 #2

Post your reply

Sign in to post your reply or Sign up for a free account.