143Mathematics · Counting and probability

Two-card sum probability with repeated values

Two-card sum probability with repeated values

Choose two different physical cards uniformly without replacement, ignoring order. Repeated numerical values still belong to distinct cards. For the listed real card values, find the probability that their sum equals S.

  • 353 bytes
  • CMPLX mode
01

Worked examples

Example 1

Original exercise 1. Choose two different physical cards uniformly without replacement, ignoring order. Repeated numerical values still belong to distinct cards. For the listed real card values, find the probability that their sum equals S. Data: M=N, count = 7; A=S = 7; v1 = 1; v2 = 1; v3 = 1; v4 = 3; v5 = 3; v6 = 4; v7 = 6.

  1. (a)Calculate all requested quantities in the stated order. Output order: probability.
Answer
|H|=5; |Ω|=21; P=5/21.
Standard solution (without a calculator)
  1. Build the mathematical model and substitute the data. Ω={(i,j):1≤i<j≤N}; |Ω|=C(N,2).
  2. Written solution: |Ω|=C(7,2)=7×6/2=21.
  3. H={(1,7), (2,7), (3,7), (4,6), (5,6)}; |H|=5.
  4. P=|H|/|Ω|=5/21=5/21.
  5. Retain exact fractions in written work; round only the final answer.
Do it on the calculator

Example 2

Original exercise 2. Choose two different physical cards uniformly without replacement, ignoring order. Repeated numerical values still belong to distinct cards. For the listed real card values, find the probability that their sum equals S. Data: M=N, count = 6; A=S = 10; v1 = 0; v2 = 0; v3 = 0; v4 = 5; v5 = 5; v6 = 10.

  1. (a)Calculate all requested quantities in the stated order. Output order: probability.
Answer
|H|=4; |Ω|=15; P=4/15.
Standard solution (without a calculator)
  1. Build the mathematical model and substitute the data. Ω={(i,j):1≤i<j≤N}; |Ω|=C(N,2).
  2. Written solution: |Ω|=C(6,2)=6×5/2=15.
  3. H={(1,6), (2,6), (3,6), (4,5)}; |H|=4.
  4. P=|H|/|Ω|=4/15=4/15.
  5. Retain exact fractions in written work; round only the final answer.
Do it on the calculator

Example 3

Original exercise 3. Choose two different physical cards uniformly without replacement, ignoring order. Repeated numerical values still belong to distinct cards. For the listed real card values, find the probability that their sum equals S. Data: M=N, count = 4; A=S = 0; v1 = -3; v2 = -3; v3 = 0; v4 = 3.

  1. (a)Calculate all requested quantities in the stated order. Output order: probability.
Answer
|H|=2; |Ω|=6; P=1/3.
Standard solution (without a calculator)
  1. Build the mathematical model and substitute the data. Ω={(i,j):1≤i<j≤N}; |Ω|=C(N,2).
  2. Written solution: |Ω|=C(4,2)=4×3/2=6.
  3. H={(1,4), (2,4)}; |H|=2.
  4. P=|H|/|Ω|=2/6=1/3.
  5. Retain exact fractions in written work; round only the final answer.
Do it on the calculator
02

When to use it

Choose two different physical cards uniformly without replacement, ignoring order. Repeated numerical values still belong to distinct cards. For the listed real card values, find the probability that their sum equals S.

Input order

  • M=N, count
  • A=S
  • v₁,…,vₙ
  • Every displayed input is required unless a blank is explicitly specified. Empty EXE keeps a stored value, whereas typing 0 replaces it with zero. The listed domain conditions must be checked even when the program does not test all of them.

Output order

  • probability
  • Record the value and press EXE.
  • The program has ended. Press AC to leave; EXE runs it again.

Conditions and limitations

  • N∈{2,3,4,5,6,7}; vⱼ,S∈ℝ.
  • vⱼ,S∈ℝ; vⱼ+vₖ=S.
  • Math ERROR: N∉{2,3,4,5,6,7}.
  • Use CMPLX, but enter real numbers only. Imaginary components are used internally as markers; do not enter card values, coordinates or thresholds with an imaginary part. Use the displayed real result as instructed.
  • Small real decimals are allowed, but comparison is numerical equality. Integers with magnitudes at most 10¹⁰ are recommended; huge values with tiny differences can be misclassified. This program shows only the final probability, not the two pair counts.
  • Every displayed input is required unless a blank is explicitly specified. Empty EXE keeps a stored value, whereas typing 0 replaces it with zero. The listed domain conditions must be checked even when the program does not test all of them.
  • Use consistent units throughout.
  • Finite precision can lose small differences between large numbers or probabilities extremely near 0 or 1. An error marker is never a valid answer.

Sign in to unlock the full programme

Checking access…

The programme code and appendix unlock together.

Checking access…

Sign in to unlock the full programme

Checking access…

The programme code and appendix unlock together.