HEX
Server: Apache
System: Linux vps.mmtprep.com 4.18.0-477.21.1.el8_8.x86_64 #1 SMP Thu Aug 10 13:51:50 EDT 2023 x86_64
User: mmtprep (1001)
PHP: 8.1.34
Disabled: exec,passthru,shell_exec,system
Upload Files
File: /home/mmtprep/public_html/mathzen.mmtprep.com/assets/4L12-25IT0cM7.js
import{E as y,m as r,r as p,aK as w,l as B}from"./index-ajJ0B2-K.js";import{b}from"./style-YtQgMMZt.js";const O="Demonstrate the equivalence of two calculation programs",Q="21/02/2022",j="",q="501f9",L="4L12";function M(){y.call(this),this.nbQuestions=1,this.nbCols=2,this.nbColsCorr=2,this.video="https://www.youtube.com/watch?v=-iw4OkMhgCA",this.testeProgrammesDeCalcul=function($,u,m,s,n,h,x,l,i){return`${b("Program A:")}<br>$${$} \\times ${u} = ${$*u}$ <br>$${$*u} ${x} ${m} = ${r($*u+m)}$ <br><br>${b("Program B:")}<br>$${$} ${l} ${s} = ${$+s}$ <br>$${$+s} \\times ${n} = ${($+s)*n}$ <br>$${($+s)*n} ${i} ${h} = ${r(($+s)*n+h)}$ <br><br>`},this.nouvelleVersion=function(){this.listeQuestions=[],this.listeCorrections=[],this.autoCorrection=[];for(let $=0,u,m,s,n,h,x,l,i,g,f,d,P=0;$<this.nbQuestions&&P<50;){const t=p(-9,9,[0]),e=p(2,6),o=p(-9,9,[0]),a=e,c=t*e+o,C=p(-9,9),v=p(-9,9,[C]);a===2?s="double":a===3?s="triple":s=`multiply by $${a}$`,c<0?(n=`remove $${-c}$`,l=""):(n=`add $${c}$`,l="+"),t<0?(h=`subtract $${-t}$`,i=""):(h=`add $${t}$`,i="+"),o<0?(x=`subtract $${-o}$`,g=""):(x=`add $${o}$`,g="+"),t*e<0?f="":f="+",t*e+o<0?d="":d="+",u=`We consider the following calculation programs:<br><br>${b("Program A:")}<br>- choose a number,<br>- the ${s},<br>- then ${n}.<br><br>${b("Program B:")}<br>- choose a number,<br>- him ${h},<br>- multiply the result by ${e},<br>- ${x}.<br><br>${w("1)")} Test these programs with the number $${C}$ and choosing any other number. Make a conjecture.<br>${w("2)")} Prove this conjecture.`,m=`${w("1)")} ${this.testeProgrammesDeCalcul(C,a,c,t,e,o,l,i,g)}Let's test these two calculation programs with the number $${v}$ for example:<br>${this.testeProgrammesDeCalcul(v,a,c,t,e,o,l,i,g)}Each time, program A gave the same result as program B.<br>We conjecture that program A will give the same result as program B for all numbers.<br><br>${w("2)")} Let's apply these two calculation programs to a number (any) which we will denote $${r("\\textit{x}")}$:<br>${b("Program A:")}<br>$ ${r("\\textit{x}")} \\times ${a} = ${a} ${r("\\textit{x}")}$<br>$${a} ${r("\\textit{x}")} ${l} ${c} = ${r(a+" \\textit{x} "+l+" "+c)}$<br><br>${b("Program B:")}<br>$ ${r("\\textit{x}")} ${i} ${t} = ${r("\\textit{x}")} ${i} ${t}$<br>$(${r("\\textit{x}")} ${i} ${t}) \\times ${e} = ${r("\\textit{x}")} \\times ${e} ${i} ${t} \\times ${e} = ${e} ${r("\\textit{x}")} ${f} ${t*e}$<br>$${e} ${r("\\textit{x}")} ${f} ${t*e} ${g} ${o} = ${r(e+" \\textit{x} "+d+" "+(t*e+o))}$<br><br>We obtained the same result with the two calculation programs.<br>As we can replace $${r("\\textit{x}")}$ by any number, we have shown that we obtain the same result with the two calculation programs for any number.`,this.questionJamaisPosee($,a,c,t,o)&&(this.listeQuestions.push(u),this.listeCorrections.push(m),$++),P++}B(this)}}export{j as dateDeModifImportante,Q as dateDePublication,M as default,L as ref,O as titre,q as uuid};
//# sourceMappingURL=4L12-25IT0cM7.js.map