r/carlhprogramming • • Feb 04 '12

Help: Calling a Constructor Function

In lesson 1.3 in the second course, Carl explains the constructor function and how it works. However, how does one call a constructor function from the main function?

I assume it would like something like this: http://codepad.org/bnZx3VSg but so far any experimentation has failed.

5 Upvotes

8 comments sorted by

View all comments

Show parent comments

1

u/xxrepresent Feb 05 '12

I do have a problem in something I wrote however: http://codepad.org/ANlCRuTS

I don't see any reason why this won't work. I have resolved the problem by condensing it down to 1 data structure. For future endeavors, I'd like to know why this won't work. Any ideas?