TMA02_TM111 with 100% correct answers
Question 1A)-The user is asked to enter a child's name. Their input, "Jamil", isstored in the variable child_name.-The user is asked to enter an amount of trip money in £. Theirinput, 20, Is stored in trip_money-The variable trip_money is then passed through an ifstatement to determine if there is any difference-The variable trip_money is less than the desired amount of24.95, so it goes into the loop. The difference is then set to24.95-trip_money, which results in the difference being set as4.95B)i)the second part of the trip_money if statement. The cost ofthe tripii)trip_costiii) beforehand, you could be asked to declare the cost of thetrip, and that value is stored in the If loopC) D)Question 2 Question 4A)(i) (ii) Show/hide answers button
Escuela, estudio y materia
- Institución
- CLC
- Grado
- CLC
Información del documento
- Subido en
- 10 de febrero de 2023
- Número de páginas
- 7
- Escrito en
- 2022/2023
- Tipo
- Examen
- Contiene
- Preguntas y respuestas
Temas
-
tma02tm111 with 100 correct answers