Login or Sign Up
Logging in...
Remember me
Log in
Or
Sign Up
Forgot password or user name?
Log in with
Search in titles only
Search in C only
Search
Advanced Search
Forums
Product Launch
Updates
Today's Posts
Member List
Calendar
Home
Forum
Topic
C
the class constructor
Collapse
X
Collapse
Posts
Latest Activity
Photos
Page
of
1
Filter
Time
All Time
Today
Last Week
Last Month
Show
All
Discussions only
Photos only
Videos only
Links only
Polls only
Events only
Filtered by:
Clear All
new posts
Previous
template
Next
priya mahajan
New Member
Join Date:
Sep 2006
Posts:
9
#1
the class constructor
Sep 20 '06, 06:12 PM
Can we say that the class constructor is a function? If yes ,then what would be its return type?
Banfa
Recognized Expert
Expert
Join Date:
Feb 2006
Posts:
9067
#2
Sep 20 '06, 06:14 PM
It is a function, it has no explicit return type but implicitly it must return void (I guess).
Comment
Post
Cancel
student
New Member
Join Date:
Sep 2006
Posts:
3
#3
Sep 20 '06, 07:43 PM
a constructor for a class is nothing but another function and it never has a return type. That's why whenever you use a constructor, you don't mention the return type explicitly
Comment
Post
Cancel
Previous
template
Next
Working...
Yes
No
OK
OK
Cancel
👍
👎
☕
Comment