public int getMathInformation(int a, char op, int b) throws RemoteException
    {
      int result = 0;


      
      if(op == '+')
        result = a + b;
      else if(op == '-')
        result = a - b;
      else if(op == 'x')
        result = a * b;
      else if(op == '/')
        result = a / b;


else if(op == '^')
        
??????????????



result = a / b;

ABOVE IS MY PROGRAM I WANT TO CALCULATE, SQUARE ROOT AND POWER OF A NUMBER

1 . 2 IS TO POWER 3 = 8
2. 2 IS THE SQURE ROOT OF 4

CAN ANY BODY HELPP ME TO WRITE THIS CODE.

THANKS
AKHAN

Read the API for the Math class.

Agree with ezzaral, the call is right in there.

Also, put your code in code tags, much easier on the eyes.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.