Recent content by Hughng

  1. Hughng

    Undergraduate Probability Textbook with Multiple Choice Practice Problems

    Would you please introduce me some textbooks that offer multiple choice or true-false questions at the end of each chapter so I can practice before my final exam? Basically, that class I am taking right now cover many central topics in Undergraduate Probability course such as: • Moments and...
  2. Hughng

    Comp Sci Difference between two dates C++

    What do you mean by that? Please help me
  3. Hughng

    Comp Sci Difference between two dates C++

    it gave me the wrong total difference days between two input dates. It gave me 727081 as the difference between 1/1/1992 and 1/1/2016
  4. Hughng

    Comp Sci Difference between two dates C++

    let me update my code. #include <iostream> #include <cmath> using namespace std; class date { private: int m; int d; int y; public: date(int, int, int); int countLeapYears(date&); int getDifference(date&); friend int operator-(const date&); }...
  5. Hughng

    Comp Sci Difference between two dates C++

    Homework Statement I am trying to solve a problem that asks me to give the total days between two dates. I have to take care of the some matters between those two dates such as leap years and the way of inputting the years by the users. (For example, if you input 1 and 17, the code will still...
  6. Hughng

    Comp Sci Unmash a string in C++ using recursion

    Homework Statement MUST USE RECURSION TO SOLVE THESE PARTS. Part A: Have a user input a string. Then display this string smashed up as follows: display the first character in the string, then the last, then the second, then the second to last, then the third... So if the string is “abcdef”, it...
  7. Hughng

    Comp Sci C++ Question: Calculate the Investment at time n

    I did not think so, but the assignment asked me to print out the desired result. I submitted the assignment, but I really appreciate your help.
  8. Hughng

    Comp Sci C++ Question: Calculate the Investment at time n

    Hello Mark, Yes, if you keep withdrawing the money given the initial amount above, you will not get the desire investment. The assignment will ask you to "cout" O for final balance, but you still have to print out the number of years that will take to exhaust your account, and the total amount...
  9. Hughng

    Comp Sci C++ Question: Calculate the Investment at time n

    The growth rate is -0.1. I am sorry I did not notice. Thank you.
  10. Hughng

    Comp Sci C++ Question: Calculate the Investment at time n

    Here are the data: Initial investment? 1000 Yearly growth rate? 0.1 Yearly withdraw amount? 20 Desired balance? 1000000 Years: 18 Balance at end: 0 Amount withdrawn over period: 340.114
  11. Hughng

    Comp Sci C++ Question: Calculate the Investment at time n

    Homework Statement Pretend you have some money (ha!) that you want to invest in the stock market. Ask the user for: The initial investmentYearly estimated market growthHow much (if any) you wish to withdraw from the account per yearThe desired level of money you wish to get The growth...
  12. Hughng

    What is the Equilibrium Position of a Pivoting Meter Stick?

    Yes I know that. I will take a look tomorrow again for my expression. Thanks a lot. I appreciate it. Have a good night!
  13. Hughng

    What is the Equilibrium Position of a Pivoting Meter Stick?

    Can you help me check out my steps please?
  14. Hughng

    What is the Equilibrium Position of a Pivoting Meter Stick?

    I think d is the distance from the center to the pivot point which is (1/2 - x)
  15. Hughng

    What is the Equilibrium Position of a Pivoting Meter Stick?

    I tried that approach but I failed. Am I annoying?
Back
Top