BREAKING: Target Test Prep releases Brand New 2026 On Demand GMAT prep course

Redeem

Target Test Prep · GMAT

Choose how you want to prepare

Learn live with an expert or move at your own pace. Every option includes the complete TTP study system.

★★★★★5.0559 reviews
GMATLiveTeach Starts Oct 17
Chris Peckover, Target Test Prep GMAT expert
LIVE ONLINE CLASSES

Get Ready for GMAT Test Day Faster with Live Online Classes

with Chris Peckover, 100th-Percentile GMAT Scorer

Oct 17 · Chris Peckover
Sat · 11:00 AM to 2:00 PM ET
Oct 20 · Chris Peckover
Tue, Thu · 8:00 to 10:00 PM ET
Oct 25 · Josh Braslow
Sun · 1:00 to 4:00 PM ET
Included
40 hours of live online classes + 6 months of TTP OnDemand
  • Attend the first class for free
  • Every class is recorded, so you never fall behind
View classes & enroll
Limited seats availableTarget Test Prep
EALiveTeachOnDemand 5 seats left Start anytime
EXECUTIVE ASSESSMENT

Target Test Prep EA OnDemand

Self-paced EA prep. Study on your schedule.

Logan Thompson
EXECUTIVE ASSESSMENT

Sep 6 to Dec 6, 2026

with Logan Thompson

165+ EA score guarantee
$05-day trial no automatic billing
Schedule
Sun · 9:30 AM to 12:30 PM ET
Included
40 hours of live online classes plus six months of access to the complete TTP EA OnDemand course.
  • 165+ EA Score Guarantee
  • 4,100+ Quant, Verbal, and Integrated Reasoning practice questions
  • 400+ hours of in-depth video lessons
  • 3,000+ step-by-step video solutions
View EA class & enroll Start free 5-day trial
Limited cohort · enrollment openTrial includes full course accessTarget Test Prep
GMATOnDemand Start anytime
SELF-PACED MASTERCLASS

Target Test Prep GMAT OnDemand

Complete access from day one. Study on your schedule.

715+ score guarantee
$0to start then $127/mo
  • Personalized study plan and analytics
  • Thousands of lessons and practice questions

Compare the format, schedule, and included access before enrolling. Prices and seat counts shown reflect the supplied offer details.

How many integers between 1 and 10^21 are such that the sum of their digits is 2?

Expert replies
Source: — Problem Solving |

BTGmoderatorDC wrote: ↑
Sun Jan 26, 2020 2:15 am
How many integers between 1 and 10^21 are such that the sum of their digits is 2?

A. 190
B. 210
C. 211
D. 230
E. 231



OA E

Source: Magoosh
If the sum of the digits of an integer is 2, then either a digit is 2 and the rest of the digits are 0 OR two digits are 1 and the rest of the digits are 0.

Case 1: One digit is 2 and the rest of the digits are 0.

Since the first digit of an integer can’t be 0, 2 must be the first digit. So between 1 and 10^21, we have: 2, 20, 200, 2000, etc. Since 2 = 2 x 10^0, 20 = 2 x 10^1, 200 = 2 x 10^2, …, and the last one being 2 x 10^20, we have 21 such numbers.

Case 2: Two digits are 1 and the rest of the digits are 0.

Notice that 10^21 is 1 followed by 21 zeros, i.e., a 22-digit number. However, it’s the smallest 22-digit number. Therefore, any number we have can only have at most 21 digits. Also, though we’ve mentioned that the first digit of an integer can’t be 0, let’s for the moment assume that it can be. Now assume that we have a 21-digit number (or code) that consists of 2 ones and 19 zeros. The number of ways to arrange 2 ones and 19 zeros is 21!/(2! x 19!) = (21 x 20 x 19!)/(2 x 19!) = 210. So there are 210 such codes and all these 210 codes are actually the numbers from 1 to 10^21 that have two digits of 1 and the rest of the digits as 0 if we omit all the initial 0s before the first digit of 1 (for example, consider 000000000000000000101 as the number 101).

Therefore, in the two cases combined, we have a total of 21 + 210 = 231 such numbers.

Answer: E

Scott Woodbury-Stewart
Founder and CEO
[email protected]

Image

See why Target Test Prep is rated 5 out of 5 stars on BEAT the GMAT. Read our reviews

ImageImage
Join the discussion