Thread: Mathematical ability and C/C++

  1. #61
    Registered User
    Join Date
    Aug 2001
    Posts
    154
    Originally posted by UneducatedOne
    I see, is that the only way to write it?
    You can write it any way you want. As long as the function calls itself, it's recursive.
    Code:
    int main()
    {
      int z = 0;
      foo(z);
      return 0;
    }
    
    void foo(x)
    {
      x++;
      while (x < 5)
       foo(x);
    }

  2. #62
    Registered User UneducatedOne's Avatar
    Join Date
    Sep 2001
    Posts
    57
    And that doesn't work in MSVisualC++?
    ~Thank you~

    some have it, some don't, watch out for those who do....

  3. #63
    Registered User UneducatedOne's Avatar
    Join Date
    Sep 2001
    Posts
    57
    Is there a good mathematics site anywhere?
    also, an easy to learn from one?
    ~Thank you~

    some have it, some don't, watch out for those who do....

  4. #64
    Has a Masters in B.S.
    Join Date
    Aug 2001
    Posts
    2,263
    im not sure about sites but if your looking to learn Algebra i would go for the Saxon's Algebra 1 'An Incremental Development ' Se. and then follow up with Algebra 2 of the same type... there pretty good books. they teach Trigonometry, Geometry, and a little Pre-Calculus, and there not fast paced and full of examples, easy to learn from.
    ADVISORY: This users posts are rated CP-MA, for Mature Audiences only.

  5. #65
    Registered User UneducatedOne's Avatar
    Join Date
    Sep 2001
    Posts
    57
    Thank you
    ~Thank you~

    some have it, some don't, watch out for those who do....

  6. #66
    Registered User UneducatedOne's Avatar
    Join Date
    Sep 2001
    Posts
    57
    Whats is "C#"?
    just another variation of C?
    ~Thank you~

    some have it, some don't, watch out for those who do....

  7. #67
    Has a Masters in B.S.
    Join Date
    Aug 2001
    Posts
    2,263
    it is basically a java like, supposedly fully object oriented language, based off of C++.
    ADVISORY: This users posts are rated CP-MA, for Mature Audiences only.

  8. #68
    Registered User
    Join Date
    Aug 2001
    Posts
    154
    Originally posted by UneducatedOne
    And that doesn't work in MSVisualC++?
    It does. I didn't give the function prototype, was just posting an example. Recursive functions are often demonstrated with factorials or fibonacci numbers in textbooks.

  9. #69
    Registered User UneducatedOne's Avatar
    Join Date
    Sep 2001
    Posts
    57
    So C# is easier/harder to learn?
    Also, is java a computer programming language? or web authoring?
    ~Thank you~

    some have it, some don't, watch out for those who do....

  10. #70
    Has a Masters in B.S.
    Join Date
    Aug 2001
    Posts
    2,263
    >So C# is easier/harder to learn?

    actually im not sure really ive never used C#.

    >Also, is java a computer programming language? or web authoring?

    Programming Language.
    ADVISORY: This users posts are rated CP-MA, for Mature Audiences only.

  11. #71
    Registered User UneducatedOne's Avatar
    Join Date
    Sep 2001
    Posts
    57
    I see, is java much the same as C++?

    or is it a whole new ball game?

    can C# be used in pretty much the same manner as C++?

    Or is it mainly java style?
    ~Thank you~

    some have it, some don't, watch out for those who do....

  12. #72
    Has a Masters in B.S.
    Join Date
    Aug 2001
    Posts
    2,263
    >I see, is java much the same as C++?
    >or is it a whole new ball game?

    its based off of C++ and is fairly similar except it uses only classes for everything.

    >can C# be used in pretty much the same manner as C++?
    >Or is it mainly java style?

    from what i've seen mainly java style, though honestly i havn't seen much of it.
    ADVISORY: This users posts are rated CP-MA, for Mature Audiences only.

  13. #73
    Registered User UneducatedOne's Avatar
    Join Date
    Sep 2001
    Posts
    57
    Thank you no-one, your a wealth of information.
    heres another one for you, do programmers generally know a lot more than just C++?
    I mean, does a "seasoned" programmer know java, pascal, basic, even web programming languages?
    ~Thank you~

    some have it, some don't, watch out for those who do....

  14. #74
    Registered User
    Join Date
    Aug 2001
    Posts
    154
    Originally posted by UneducatedOne
    Thank you no-one, your a wealth of information.
    heres another one for you, do programmers generally know a lot more than just C++?
    I mean, does a "seasoned" programmer know java, pascal, basic, even web programming languages?
    I'm hardly a seasoned programmer, but my take is that many programmers know several languages, although they may concentrate in one or two. C/C++ is a good one, because many other languages are based on or similar to them. I've done some Perl, VB, unix shell scripting, dos batch files, and there are a lot of common elements among them. Sometimes the differences are confusing because of that. I can be writing in one language and put in elements of another.

  15. #75
    Has a Masters in B.S.
    Join Date
    Aug 2001
    Posts
    2,263
    >Thank you no-one, your a wealth of information.

    your quite welcome.

    >
    heres another one for you, do programmers generally know a lot more than just C++?
    I mean, does a "seasoned" programmer know java, pascal, basic, even web programming languages?
    <

    Brown Drake, it right, usually they concentrate on a single language till they have become expert in it, and move to a wide range of others sometimes even before becoming expert, a lot of the time it depends on the job their doing, but a sound base in one will help in other languages for sure.
    ADVISORY: This users posts are rated CP-MA, for Mature Audiences only.

Popular pages Recent additions subscribe to a feed