diff --git a/your-code/main.ipynb b/your-code/main.ipynb index b8b7a9c..0a0aa62 100644 --- a/your-code/main.ipynb +++ b/your-code/main.ipynb @@ -25,7 +25,29 @@ "source": [ "\"\"\"\n", "your solution here\n", - "\"\"\"" + "\"\"\"\n", + "'''\n", + "P(A∪B) = P(A)+P(B)-P(A∩B)\n", + "P(AUB)= 0.3+0.6-0.1\n", + "P(AUB)=0.8'''#First 1 is false\n", + "'''\n", + "P(Ā) = 1-P(A)\n", + "P(notB) = 1-0.6\n", + "P(notB)= 0.4\n", + "P(A∩B-)=P(A)-P(A∩B)\n", + "P(A∩B-)=0.3-0.1\n", + "P(A∩B-)=0.2'''#Second one is True\n", + "'''\n", + "P(BuB-)=-0.3+0.4\n", + "P(A∩(BuB-))= 0.3+0.1\n", + "P(A∩(BuB-))=0.4'''#Third one is True\n", + "'''\n", + "P(notAuB)=1-0.8\n", + "P(notAuB)=0.2\n", + "'''#The Fouth one is False\n", + "'''P(A∩B)=1-0.1\n", + "P(notAuB)=0.9\n", + "'''#The Fifth is True" ] }, { @@ -49,7 +71,12 @@ "outputs": [], "source": [ "\"\"\"\n", - "your solution here\n", + "your solution \n", + "nb=30 wb=10 rb=12 bb=8\n", + "1/3 Taking a white ball out.\n", + "10/29 Taking a white ball out after taking a black ball out.\n", + "11/28 Taking a red ball out after taking a black and a red ball out.\n", + "2/5 Taking a red ball out after taking a black and a red ball out with reposition.\n", "\"\"\"" ] }, @@ -76,6 +103,12 @@ "source": [ "\"\"\"\n", "your solution here\n", + "Prc=50% Pc=40% Pr=10%\n", + "Prd=(Prc,Prc-),40%,10%\n", + "P(A|B)=P(B|A)*P(A)/P(B)\n", + "P=P(0.5)*0.1/0.4\n", + "P=0.125\n", + "What is the probability of rain, given the day started cloudy?12.5%\n", "\"\"\"" ] }, @@ -106,7 +139,7 @@ "metadata": {}, "outputs": [], "source": [ - "# your code here" + "# your code here\n" ] }, { @@ -117,6 +150,14 @@ "source": [ "\"\"\"\n", "your solution here\n", + " Y N T Py Pn\n", + "M 324 156 480 67.5 32.5 \n", + "F 351 169 520 67.5 32.5\n", + "T 675 325 100067.5 32.5\n", + "\n", + "They are independent as the Prob are the same\n", + "\n", + "\n", "\"\"\"" ] }