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/6D13-RPN5hXzx.js.map
{"version":3,"file":"6D13-RPN5hXzx.js","sources":["../../src/exercices/6e/6D13.js"],"sourcesContent":["import { combinaisonListes } from '../../lib/outils/arrayOutils'\nimport { texteEnCouleur } from '../../lib/outils/embellissements'\nimport { sp } from '../../lib/outils/outilString.js'\nimport { context } from '../../modules/context.js'\nimport Hms from '../../modules/Hms'\nimport { ajouteChampTexteMathLive } from '../../lib/interactif/questionMathLive.js'\n\nimport { calculANePlusJamaisUtiliser, listeQuestionsToContenu, randint } from '../../modules/outils.js'\nimport Exercice from '../Exercice.js'\nimport { setReponse } from '../../lib/interactif/gestionInteractif.js'\n\nexport const titre = 'Convert min to h and min or s to min and s'\nexport const interactifReady = true\nexport const interactifType = 'mathLive'\nexport const amcReady = true\nexport const amcType = 'AMCHybride'\nexport const dateDeModifImportante = '14/05/2022'\n\n/**\n *\n * @author\n * Référence 6D13\n * Ajout d'une option \"Mélange\" par Guillaume Valmont le 14/05/2022\n */\nexport const uuid = '4f8f4'\nexport const ref = '6D13'\nexport default function ConversionHeuresMinutesOuMinutesEtSecondes (can = false) {\n  Exercice.call(this)\n  this.nbQuestions = 5\n  this.correctionDetailleeDisponible = true\n  this.correctionDetaillee = false\n  this.sup = 1\n  this.nouvelleVersion = function () {\n    this.listeQuestions = []\n    this.listeCorrections = []\n    this.autoCorrection = []\n    let typeQuestionsDisponibles = ['min to h and min', 's to min and s']\n    if (this.sup === 1) typeQuestionsDisponibles = ['min to h and min']\n    else if (this.sup === 2) typeQuestionsDisponibles = ['s to min and s']\n    const listeTypeQuestions = combinaisonListes(typeQuestionsDisponibles, this.nbQuestions)\n    for (let i = 0, cpt = 0, a, b, d, texte, texteCorr; i < this.nbQuestions && cpt < 50;) {\n      a = randint(2, 4)\n      b = randint(10, 59)\n      d = calculANePlusJamaisUtiliser(a * 60 + b)\n      if (listeTypeQuestions[i] === 'min to h and min') {\n        texte = `Convert $${d}$ minutes to hours (h) and minutes (min).` + ajouteChampTexteMathLive(this, i, 'inline keyboardHms')\n        this.canEnonce = `Convert $${d}$ minutes to hours and minutes.`\n        this.canReponseACompleter = '$\\\\ldots$ h $\\\\ldots$ min'\n      } else {\n        texte = `Convert $${d}$ seconds to minutes (min) and seconds (s).` + ajouteChampTexteMathLive(this, i, 'inline keyboardHms')\n      }\n      if (can) {\n        if (listeTypeQuestions[i] === 'min to h and min') {\n          texteCorr = texteEnCouleur(`\n    Mentalement : <br>\nOn cherche le multiple de $60$ inférieur à $${d}$ le plus grand possible. C'est $${Math.floor(d / 60)}\\\\times 60 = ${Math.floor(d / 60) * 60}$.<br>\nAinsi $${d} = ${Math.floor(d / 60) * 60} + ${d % 60}$ donc $${d}$min $= ${Math.floor(d / 60)}$${sp(1)}h${sp(1)}$${d % 60}$${sp(1)}min.`) + '<br>'\n        } else {\n          texteCorr = texteEnCouleur(`\n           Mentalement : <br>\n      On cherche le multiple de $60$ inférieur à $${d}$ le plus grand possible. C'est $${Math.floor(d / 60)}\\\\times 60 = ${Math.floor(d / 60) * 60}$.<br>\n      Ainsi $${d} = ${Math.floor(d / 60) * 60} + ${d % 60}$ donc $${d}$s $= ${Math.floor(d / 60)}$${sp(1)}min${sp(1)}$${d % 60}$${sp(1)}s.`) + '<br>'\n        }\n        this.listeCanEnonces.push(this.canEnonce)\n        this.listeCanReponsesACompleter.push(this.canReponseACompleter)\n      } else {\n        if (this.correctionDetaillee) {\n          texteCorr = `We must carry out the Euclidean division of ${d} by 60 because there are 60 minutes in an hour.<br>The integer quotient gives the number of hours and the remainder enter gives the number of minutes.<br>`\n        } else {\n          texteCorr = ''\n        }\n      }\n      if (listeTypeQuestions[i] === 'min to h and min') {\n        texteCorr += `$${d} = ${a} \\\\times 60 + ${b}$ so $${d}$ minutes = $${a}$${sp(1)}h${sp(1)}$${b}$${sp(1)}min.`\n      } else {\n        texteCorr += `$${d} = ${a} \\\\times 60 + ${b}$ so $${d}$ s = $${a}$${sp(1)}min${sp(1)}$${b}$${sp(1)}s.`\n      }\n      if (this.questionJamaisPosee(i, a, b, d)) {\n        this.listeQuestions.push(texte)\n        this.listeCorrections.push(texteCorr)\n        if (context.isAmc) {\n          if (listeTypeQuestions[i] === 'min to h and min') {\n            this.autoCorrection[i] = {\n              enonce: texte,\n              options: { multicols: true },\n              propositions: [\n                {\n                  type: 'AMCNum',\n                  propositions: [{\n                    texte: texteCorr,\n                    statut: '',\n                    reponse: {\n                      texte: 'Hours)',\n                      valeur: a,\n                      param: {\n                        digits: 1,\n                        decimals: 0,\n                        signe: false,\n                        approx: 0\n                      }\n                    }\n                  }]\n                },\n                {\n                  type: 'AMCNum',\n                  propositions: [{\n                    texte: '',\n                    statut: '',\n                    reponse: {\n                      texte: 'Minute(min)',\n                      valeur: b,\n                      param: {\n                        digits: 2,\n                        decimals: 0,\n                        signe: false,\n                        approx: 0\n                      }\n                    }\n                  }]\n                }\n              ]\n            }\n          } else {\n            this.autoCorrection[i] = {\n              enonce: texte,\n              options: { multicols: true },\n              propositions: [\n                {\n                  type: 'AMCNum',\n                  propositions: [{\n                    texte: texteCorr,\n                    statut: '',\n                    reponse: {\n                      texte: 'Minutes(min)',\n                      valeur: a,\n                      param: {\n                        digits: 1,\n                        decimals: 0,\n                        signe: false,\n                        approx: 0\n                      }\n                    }\n                  }]\n                },\n                {\n                  type: 'AMCNum',\n                  propositions: [{\n                    texte: '',\n                    statut: '',\n                    reponse: {\n                      texte: 'Seconds',\n                      valeur: b,\n                      param: {\n                        digits: 2,\n                        decimals: 0,\n                        signe: false,\n                        approx: 0\n                      }\n                    }\n                  }]\n                }\n              ]\n            }\n          }\n        } else {\n          if (listeTypeQuestions[i] === 'min to h and min') {\n            setReponse(this, i, new Hms({ hour: a, minute: b }), { formatInteractif: 'hms' })\n          } else {\n            setReponse(this, i, new Hms({ minute: a, second: b }), { formatInteractif: 'hms' })\n          }\n        }\n\n        i++\n      }\n      cpt++\n    }\n    listeQuestionsToContenu(this)\n  }\n  this.besoinFormulaireNumerique = ['Starting unit type', 3, '1: Minutes\\n2: Seconds\\n3: Mix']\n}\n"],"names":["titre","interactifReady","interactifType","amcReady","amcType","dateDeModifImportante","uuid","ref","ConversionHeuresMinutesOuMinutesEtSecondes","can","Exercice","typeQuestionsDisponibles","listeTypeQuestions","combinaisonListes","i","cpt","a","b","d","texte","texteCorr","randint","calculANePlusJamaisUtiliser","ajouteChampTexteMathLive","texteEnCouleur","sp","context","setReponse","Hms","listeQuestionsToContenu"],"mappings":"kHAWY,MAACA,EAAQ,6CACRC,EAAkB,GAClBC,EAAiB,WACjBC,EAAW,GACXC,EAAU,aACVC,EAAwB,aAQxBC,EAAO,QACPC,EAAM,OACJ,SAASC,EAA4CC,EAAM,GAAO,CAC/EC,EAAS,KAAK,IAAI,EAClB,KAAK,YAAc,EACnB,KAAK,8BAAgC,GACrC,KAAK,oBAAsB,GAC3B,KAAK,IAAM,EACX,KAAK,gBAAkB,UAAY,CACjC,KAAK,eAAiB,CAAE,EACxB,KAAK,iBAAmB,CAAE,EAC1B,KAAK,eAAiB,CAAE,EACxB,IAAIC,EAA2B,CAAC,mBAAoB,gBAAgB,EAChE,KAAK,MAAQ,EAAGA,EAA2B,CAAC,kBAAkB,EACzD,KAAK,MAAQ,IAAGA,EAA2B,CAAC,gBAAgB,GACrE,MAAMC,EAAqBC,EAAkBF,EAA0B,KAAK,WAAW,EACvF,QAASG,EAAI,EAAGC,EAAM,EAAGC,EAAGC,EAAGC,EAAGC,EAAOC,EAAWN,EAAI,KAAK,aAAeC,EAAM,IAChFC,EAAIK,EAAQ,EAAG,CAAC,EAChBJ,EAAII,EAAQ,GAAI,EAAE,EAClBH,EAAII,EAA4BN,EAAI,GAAKC,CAAC,EACtCL,EAAmBE,C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