Search:

Type: Posts; User: Khalidkamalabdr

Search: Search took 0.01 seconds.

  1. Not exactly sure what this part of code does in this overloading demonstration

    #include<iostream>
    using namespace std;


    class complex
    {
    float x,y;


    public:
  2. I never knew there was an "or" expression :S! Ok...

    I never knew there was an "or" expression :S! Ok so instead of "&&" I can just use "||",that's pretty simple and will do just fine. Hmmm making a function to do the logic for me, I understand but I...
  3. Hmmm,makes a lot of sense thank you. I'm going to...

    Hmmm,makes a lot of sense thank you. I'm going to have to schedule this code-shortening to another time though because in the mean time I'm working on the binary to hexadecimal conversion code. Be...
  4. Hmmm. This seems to be calculating the values...

    Hmmm. This seems to be calculating the values properly. Why did you use d[] though? Don't I still have to re-arrange the values?
  5. I figured. I didn't indent the code properly at...

    I figured. I didn't indent the code properly at all,sorry! Ok NOW I get it,thanks a bunch :biggrin:!
  6. To: Whiteflags Thank you. Your observations...

    To: Whiteflags

    Thank you. Your observations were really useful. Although I didn't understand why you think counterd would become negative on entry of a binary number of at least 1 digit. It's...
  7. Hmmm,you are absolutely right! Thank you :D....

    Hmmm,you are absolutely right! Thank you :D. Normaly when I write the code I think of what will get the job done then I think maybe afterwards I work on making it compact and beautiful but I always...
  8. Oh yes ok.I got it now. I thought the link...

    Oh yes ok.I got it now. I thought the link was...never mind its just that a lot of members have like a link at the bottom of their comments that apparently aren't part of the comments ,give me a...
  9. Problem with a binary to decimal conversion program. Help please.

    So I tried debugging this program almost 10 times, each time finding a problem then making code to fix it, I used to get wrong values but then now after I changed the calculation from an infinity...
  10. I don't know what you mean. Would you please tell...

    I don't know what you mean. Would you please tell me what you mean by "readable"?
  11. I barely got parts of that code :frown:. I'm...

    I barely got parts of that code :frown:. I'm still a beginner you know lol.
  12. The new shorter code (thanks again guys)

    #include<iostream>
    using namespace std;


    int decimal_to_binary(int decb)
    {

    int counterb;
    int round=0;
    int h[10]; //0-9 means 10 won't forget it again
  13. Thank you, I get it now :).

    Thank you, I get it now :).
  14. Thank you so much :D. I was actually looking for...

    Thank you so much :D. I was actually looking for a way to do exactly what you just did, to have the index dependent on a variable but I didn't know how :S I'm still a beginner you know lol. I can't...
  15. Problem with program that uses a function to convert decimal values to binary values.

    The program works fine until I start using 6 digits or more, then I just get the first value of my binary number.
    I have the menu part in main because I'm planning on doing all the other conversions...
  16. Yes, it worked! Why didn't I notice that?! Thank...

    Yes, it worked! Why didn't I notice that?! Thank you,but I AM a bit curious about the fact that it did work but made that small mistake even with just an assignment operator instead on an equality...
  17. I need help with this C++ program that adds matrices and edits the result.

    The program adds 2 matrices that are 3x3 using arrays and then stores them into another matrix (array) and then it's edited to show a diagonal line of "0" through it, btw I'm pretty new to...
Results 1 to 17 of 17