Solved

Return type

Posted on 2008-10-09
4
188 Views
Last Modified: 2013-11-23
Hi

I have a question.

what's the return type in this code?

Is it setDate?

public void setDate(int day, int month, int year)

Open in new window

0
Comment
Question by:bt1942
  • 2
4 Comments
 
LVL 59

Accepted Solution

by:
Kevin Cross earned 400 total points
ID: 22682956
(void) ==> Nothing is returned.  If you think in terms of subs and functions, this would be a sub.
0
 
LVL 59

Assisted Solution

by:Kevin Cross
Kevin Cross earned 400 total points
ID: 22682978
If you need further clarification, see this portion of the Java Tutorials:
http://java.sun.com/docs/books/tutorial/java/javaOO/methods.html
0
 
LVL 10

Assisted Solution

by:peetm
peetm earned 100 total points
ID: 22683097
Subroutines are invoked for their 'behaviour' [or 'side effect'], whereas functions are invoked, so that the invokation results in some 'value' - the function is resolved to some value that is then used further in an expression.
0
 

Author Closing Comment

by:bt1942
ID: 31504855
Thanks for the comment!
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This article will show, step by step, how to integrate R code into a R Sweave document
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now