Chat with our AI personalities
There is no four digit number where the ones is twice the tens, the hundreds is five less than the ones, and the thousands is the sum of the tens and hundreds. int ones, tens, hundreds, thousands; for (thousands=1; thousands<10; thousands++) { /**/ for (hundreds=0; hundreds<10; hundreds++) { /**/ /**/ for (tens=0; tens<10; tens++) { /**/ /**/ /**/ for (ones=0; ones<10; ones++) { /**/ /**/ /**/ /**/ if (ones != 2 * tens) break; /**/ /**/ /**/ /**/ if (hundreds != ones - 5) break; /**/ /**/ /**/ /**/ if (thousands != tens + hundreds) break; /**/ /**/ /**/ /**/ printf ("dd\n", thousands, hundreds, tens, ones); /**/ /**/ /**/ } /**/ /**/ } /**/ } }
100 = (9x10) + (10x1) = 90 + 10
The general function is:1. y = a*x+bb is irrelevant and we can be removed2. y = a*xlets split x into ones and tens3. x = tens*10 + ones /e.g. 23 = 2*10 + 34. p1 = Multiplier of the onesp2 = Multiplier of the tens5. y = tens*10*p2 + ones*p1 /according to the question6. x*a = tens*10*p2 + ones*p1 /according to 2.7. (tens*10 + ones)*a = tens*10*p2 + ones*p1 /according to 3.8. tens*10*a + ones*a = tens*10*p2 + ones*p1 /regroup9. tens*10*a - tens*10*p2 + ones*a - ones*p1 = 0 /regroup10. tens*10*(a-p2) + ones*(a-p1) = 0 /regroup11. assuming "tens" and "ones" are not 0 then (a-p2) and (a-p1) must be 012. a-p2 = 0a-p1 = 013. a = p2a = p114. a = p1 = p2the answer is: when the Multipliers of ones and tens are equal then the product is called a.
What number has 9 tens and 4 fewer ones than tens
There are 8 tens in 80 ones. This is because in the base-10 number system, each group of 10 ones makes a unit of ten. Therefore, when you have 80 ones, you can divide it by 10 to find out how many tens there are, which in this case is 8.