Code:
//libraries
#include<iostream.h>
#include<conio.h>

void main()
{ //declare the variables
    int i[3][10];
   char c[2][10];
   int bil;

//promt the user to enter the number
   cout<<"Masukkan bilangan digit : ";
   cin>>bil;

//loop for enter 2 difference number
   for(int y=0;y<2;y++)
   {
        //loop for enter the number   
       for (int x=bil-1;x>=0;x--)
       {
       cin>>c[y][x];
       }
   }

//loop for convert the 2 numbers into int
   for(int y=0;y<2;y++)
   {
       for (int x=bil-1;x>=0;x--)
       {
       i[y][x]=(int)c[y][x];
       }
   }

//Display result
    for(int y=0;y<2;y++)
   {
       for (int x=bil-1;x>=0;x--)
       {
       cout<<i[y][x]<<"   ";

       }  cout<<endl;
   }

 //this part not understand
int b=0;
       for (int x=bil-1;x>=0;x--)
       {
       i[2][x]=i[0][x]+i[1][x]+b;
      if(i[2][x]>10)
         {
          i[2][x]=i[2][x]-10;
          b=1;
          }
      else
          b=0;
       }

//Display result
       for (int x=0;x<bil;x++)
       {
       cout<<i[2][x]<<"   ";

       }  

   getch();
   }
this is the rough coding i did.. but this is only for addition..i am still trying to do for subtraction

Thx for helping

Last edited by DaWei; 18Oct2007 at 19:30.. Reason: Added code tags.