subject

Javascript function: we will add a user input that asks the user to enter the number of job duties that they want to see that you preformed at your previous job. When the user clicks a button, a function will be called and will then take this input and use it to specify an index number of an array that will be the starting point of the array values (duties) to be displayed. Through looping, we will then subtract 1 from the index number until it reaches 0 and display all of the values that are associated with the index numbers that were calculated during the loop. Create an input that acts as a fill in the blank for a sentence that prompts the user to enter the number of job duties they want to see. Create a button that calls a function when clicked (the function created in the next step) Crate a function that takes the user input and assigns the value to a variable. Create an array with at least five job duties in it. ( cooking, cleaning, organizing, getting groceries and walking dog) 5. Create a while loop that runs while the variable (that represents the index value that we want to print) is greater than or equal to the minimum array value. Within the while loop have two things happen. Have the innerHTML of some element within your page be replaced with the array value that corresponds to the index number that we want printed You specify the array value by the format arrayname[indexnumber] Have the index subtract one from itself to count down At this point your function should run, but it does not work properly. Only the array value at the last index is printed. To fix this, we need to concatenate the results of the loop. i. Create a new variable outside of the loop and set it to be equal to blank (You do this by setting it equal to "") Within the loop, make this variable to be equal to itself plus the array value that we want printed. Now change the innerHTML to be equal to this variable.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 07:30
Jasper and samantha are in a robotics competition. the guidelines state that the robots should be able to move a 10-gram weight at least 2 meters and turn in a circle. jasper and samantha have already built the robot. which step of the design process should they follow next to decide whether their robot meets the minimum criteria for the competition?
Answers: 1
question
Computers and Technology, 22.06.2019 08:00
What best describes a career pathway in a lodging career? a worker starts out as an amusement attendant, then becomes a recreation worker, and then becomes a gaming worker within five years. a worker starts out as a bell hop, then becomes a night clerk, and then becomes a hotel manager within five years. a worker starting out as a tour guide, then becomes a travel clerk, and then becomes a travel agent within five years. a worker starts out as a server, then becomes a food preparer, and then becomes a head chef within five years.
Answers: 1
question
Computers and Technology, 23.06.2019 01:50
Create a class named majors that includes an enumeration for the six majors offered by a college as follows: acc, chem, cis, eng, his, phys. display the enumeration values for the user, then prompt the user to enter a major. display the college division in which the major falls. acc and cis are in the business division, chem and phys are in the science division, and eng and his are in the humanities division. save the file as majors.java.
Answers: 2
question
Computers and Technology, 23.06.2019 02:00
Which demographic challenge is europe currently experiencing? a. an aging and decreasing population b. a baby boomc. an unequal distribution between males and females d. a large group of teenagers moving through the school system(i chose a but i'm unsure)
Answers: 1
You know the right answer?
Javascript function: we will add a user input that asks the user to enter the number of job duties t...
Questions
question
Mathematics, 22.05.2020 08:01
question
Mathematics, 22.05.2020 08:01
question
Mathematics, 22.05.2020 08:01
question
History, 22.05.2020 08:01
Questions on the website: 13722367