Jump to content
Hertz

[Programare]Combinatii

Recommended Posts

Posted

Se da formula unei combinatii matematice.

n C r

unde n e numarul total de selectii si r este numarul pe care il alegi.

Formula de evaluare e:

n!

r! (n-r)!

Care e raspunsul cand evaluezi aceasta expresie.

17 C 10 - 30 C 12 + 50 C 3

Posted

de fapt

17C10=8*11*13*17=19,448

30C12=13*7*15*16*17*18*19*21*23*24*25*29=1,067,146,490,592,000

50C3=8*49*50=19,600

-1,067,146,490,379,952

uh ma pierd la calculatul termenilor. Ideea problemei ca pui 50!/47!=48*49*50 si apoi elimini termenii din fractie ...

Posted

Ai gresit la C(30,12). Daca tii neaparat sa faci prin metoda asta, atunci C(30,12) ar fi 3 * 7 * 13 * 19 * 23 * 25 * 29.

Totusi, e mult mai la indemana sa folosesti WolframAlpha pentru asta sau chiar calculatorul de la Windows :).

Rezultatul este, dupa cum a spus si Hertz, -86454177.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...