#include void placeValue(int num, int &thousandValue, int &hundredValue, int &tensValue, int &onesValue){ thousandValue = num/1000; hundredValue = (num/100)%10; tensValue = (num/10)%10; onesValue = num%10; } int main(){ int num,thousandValue,hundredValue,tensValue,onesValue; cout << "Enter a 4 Digit Number: "; cin >> num; cout << endl; placeValue(num,thousandValue,hundredValue,tensValue,onesValue); cout << thousandValue << " is in the thousands value\n"; cout << hundredValue << " is in the hundreds value\n"; cout << tensValue << " is in the tens value\n"; cout << onesValue << " is in the ones position\n"; return (0); }