Sized from the IRC 2021 deck tables: southern pine No. 2, 40 psf live load, 16 in joist spacing, the deck surface 4 ft off the ground. A deck on a ledger at the house with one beam along the outer edge. Your town can amend the code and will want a permit, so show it these plans first.
Estimate for planning only, not professional advice. Check the manufacturer’s instructions, your local code and a licensed professional before you buy, build or install. Use at your own risk. Terms.
Short answer
10 × 12: 2x8 joists, 3 posts; 12 × 12: 2x10 joists, 3 posts; 12 × 16: 2x10 joists, 3 posts; 16 × 20: 2x12 joists, 4 posts. The joist size follows how far the deck sticks out from the house; the posts follow how long it runs along it.
10 × 12 deck: 10 ft out, 12 ft along the house
Joists
10 × 2x8 at 16 in on center, spanning 10 ft (the table allows 11 ft 10 in)
Beam
2-ply 2x8, along the outer edge
Posts
3 × 4x4, 6 ft apart (the beam allows 6 ft 9 in), about 32½ in tall
Decking
1 1/4 in wood (5/4) boards run across the joists at 16 in on center
Footings, the ledger's fastening to the house, lateral load connectors, guards and stairs depend on your house, soil and height, so the code covers them separately (IRC R507.3 for footings, R507.9 for the ledger and lateral connections). The American Wood Council's free deck guide, DCA 6, shows those details. Guards are needed once the deck is more than 30 in off the ground: see deck railing height and stair code.