Hi Faldrax
Never mind, I got it right eventually. C++ want you to think in chronological manner and visualise what you want to do as well as a lot of practice.
Thanx Man
int main ( )
{
int number,dig1,dig2,dig3,dig4,second,third,fourth;
cout << "Enter a 4 digit number " ;
cin >> number;
// Obtain FIRST Digit
dig1 = number / 1000;
// Obtain SECOND digit
second = (number-dig1) / 100;
dig2 = second % 10;
// Obtain THIRD Digit
third = number / 10;
dig3 = third % 10;
// Obtain FOURTH Digit
fourth = number / 1;
dig4 = fourth % 10;
// The answer for the equation: (first digit multiplied by 3), plus (second digit multiplied by third didit) minus fourth digit
cout << (dig1 * 3) + (dig2 * dig3) - dig4 << endl;
return 0;
}