Results 1 to 2 of 2

Thread: C and C++ in .Net 2005 environment

  1. #1
    Junior Member
    Join Date
    Aug 2007
    Answers
    16

    C and C++ in .Net 2005 environment

    Hello friends,

    Plz can u solve my doubts

    1)why C++ language is called as a partial object oriented language.

    2)can we do C and C++ programs in .net 2005 environment.if so plz can u tell the procedure for it.ie steps to do.

    3)In C,C++ language we can swap two values by using call by value?
    In c# by using call by value,can we swap two numbers.the values are swapping for but in the result it is not showing the swapped values.
    the pgm which i wrote is

    In the form I have taken a button.
    In general declaration

    class test
    {
    public void swap(int x, int y)
    {
    int t = x;
    x = y;
    y = t;
    MessageBox.Show("x = " + x.ToString());
    MessageBox.Show("y = " + y.ToString());
    }
    }

    In button_click

    {
    test t = new test();
    int a=10,b=20;
    t.swap(a, b);
    MessageBox.Show(a.ToString() + " " + b.ToString());

    }

    plz mail the answers to aru576 @ yahoo . co . in

    Thanks and bye
    waiting for u r reply.


  2. #2
    Junior Member
    Join Date
    Oct 2007
    Answers
    1

    Re: C and C++ in .Net 2005 environment

    From ur code, I understand that you are not returning the swaped values back to the calling code. Try to return it back and it will work fine.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact