Basic FunctionsIntermediate

Reduce a batch of screen resolutions to their simplest aspect ratio with GCD

A resolution's aspect ratio is just its width and height with every factor they share divided back out, and GCD is what finds that shared factor without you having to guess it.

Task:

Facilities is auditing which displays around the office can show the same content side by side without one of them letterboxing, and that comes down to aspect ratio, not raw resolution. For each display in B2:C5, find the greatest common factor of its width and height, divide both by it to get the simplest whole-number ratio, and join the two results into a label like "16:9". Fill in column D for rows 2 through 5.

Interactive Spreadsheet

Hints

+5 XPno-hints bonus

Solve it on your own to keep the bonus. Each hint gets one step closer to the formula.

The data in this exercise

This is the grid you start with. Cell references in the task — B6, C2 — point at the row numbers and column letters below.

5 rows × 4 columns4 cells you fill in
ABCD
1DisplayWidth (px)Height (px)Aspect Ratio
2Conference Room Display19201080
3Old Training Room Projector1024768
4Finance Dept Ultrawide Monitor25601080
5Warehouse Floor Monitor1600900
What this exercise teachesMay contain the answer

GCD(B4,C4) finds the largest number that divides both 2560 and 1080 evenly — 40 — and dividing each side by that same 40 is what strips out every factor they shared, leaving the smallest whole numbers that still describe the same shape. For three of the four displays that lands on a tidy 16:9, but the ultrawide monitor reduces to 64:27, not the 21:9 it is marketed as: 2560 by 1080 only looks like 21:9, it isn't quite that, and GCD doesn't round to the nearest familiar name — it returns the ratio the pixels actually are.