https://github.com/ci-wdi-900/ XXXXXXXXXXmidterm

1 answer below »
https://github.com/ci-wdi-900/2021-10-24-midterm
Answered Same DayOct 25, 2021

Answer To: https://github.com/ci-wdi-900/ XXXXXXXXXXmidterm

Shubham Kumar answered on Oct 25 2021
129 Votes
Assignment/Documentation.doc
Introduction :
The assignment was a Javascript Assignment, that invol
ved creating functions for various functionalities.
Requirements :
Main.js was needed to be completed with the functions. Further, the functions were to be tested against a given test case file, and corrected if any discrepancies were found.
Application and Implementation :
Basic understanding of Javascript
Javascript Arrays, Loops and Function Declarations
Output ScreenShots :
You can see in the bottom that all the tests have passed, which was the motive of the assignment.
Assignment/main.js
// ┌─────────────────┐
// │ Your code here! │    
// └─────────────────┘
function ageToAbilities(age) {
let result = "";
if(age<16) {
result = "You can't drive.";
} else if(age>=16 && age<=17) {
result = "You can drive but not vote.";
} else if(age>17 && age<=24) {
result = "You can vote but not rent a car."
} else {
result =...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here