Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

6
  • 1
    Ick... #include "stdafx.h"? You need the other three, but you can definitely do without stdafx.h. Oh, and main is supposed to return an integer. Commented Aug 24, 2010 at 2:34
  • 1
    @D. Shawley: c++ actually has a rule saying that main is a special case and may have the return 0; omitted resulting in the same effect as if you had put it there. Commented Aug 24, 2010 at 3:07
  • What happens if I call the first function like this: convert_string_to_number("blah")? As it is, this will silently fail and return the same as if I'd called convert_string_to_number("0"). That''s a definitive -1 from me. Commented Aug 24, 2010 at 8:17
  • 1
    Why the downvote? I voted up, it gets the point across just fine, even if the headers/main function is questionable. Commented Aug 24, 2010 at 11:11
  • Thanks Ashley. Appreciate your response. Commented Aug 24, 2010 at 22:59