1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
erica [24]
2 years ago
8

1. what is the purpose of giving an id to an html element when using javascript?

Computers and Technology
1 answer:
bazaltina [42]2 years ago
3 0

Answer:

It is also used by JavaScript to access and manipulate the element with the specific id.

You might be interested in
Design a program that asks the user to enter a store’s sales for each day of the week. The amounts should be stored in an array.
sdas [7]

Answer:

Program given below

Explanation:

Total Sales

Assign the values of the variable as “Enter the store sales for Sunday” in Sun

Assign the values of the variable as “Enter the store sales for Monday” in Mon

Assign the values of the variable as “Enter the store sales for Tuesday” in Tue

Assign the values of the variable as “Enter the store sales for Wednesday” in Wed

Assign the values of the variable as “Enter the store sales for Thursday” in Thu

Assign the values of the variable as “Enter the store sales for Friday” in Fri

Assign the values of the variable as “Enter the store sales for Saturday” in Sat

Assign the values for the variable in array as [Sun, Mon, Tue, Wed, Thu, Fri, Sat]

Initialize tot = 0

Use the loop for calculating the total sales for the week,

for total_sales in store_sales:

    tot += total_sales

then display the result as,    

print "\n Total week sales = %2.f " %tot

sun = int(input("\n Enter the store sales for Sunday: "))

mon = int(input("\n Enter the store sales for Monday: "))

tue = int(input("\n Enter the store sales for Tuesday: "))

wed = int(input("\n Enter the store sales for Wednesday: "))

thu = int(input("\n Enter the store sales for Thursday: "))

fri = int(input("\n Enter the store sales for Friday: "))

sat = int(input("\n Enter the store sales for Saturday: "))

store_sales = [sun, mon, tue, wed, thu, fri, sat]

tot = 0

for store_sale in store_sales:

tot += store_sale

print "\n Total Week Sales: %2.f" %tot

We will have the following output:

<u>OUTPUT </u>

<u> </u>Enter the store sales for Sunday: 45

Enter the store sales for Monday: 56

Enter the store sales for Tuesday: 89

Enter the store sales for Wednesday:78

Enter the store sales for Thursday: 45

Enter the store sales for Friday: 12

Enter the store sales for Saturday: 23

Total Week Sales: 348

8 0
3 years ago
Which code snippet could be used to print the following series?
GaryK [48]
C is the answer, I think
7 0
1 year ago
Answer to this if you have apex legends on either pc xbox one or PS4 for the one that answers and does gets brainliest please do
weqwewe [10]

Answer:

I got it on Ps4

3 0
2 years ago
Read 2 more answers
You don’t design new software. Instead, you work with software that already exists to be sure that it keeps running smoothly. Wh
Arada [10]

Answer:

Explanation:

If you are developing software products, run complex projects, you should ... All the same, to make the right choice of an SDLC methodology, you ... Generally, there are stages involved in all the different methodologies. ... You will therefore have to keep both the old and new systems running for some time.

5 0
2 years ago
Read 2 more answers
You have $5 and earn $1.75 for each roll of wrapping paper you sell. Write an equation in two variables that represents the tota
qaws [65]

Answer:

A = 5 + 1.75r

Explanation:

Amount you have = $5

Earning per roll of wrapping paper = $1.75

Let

r = number of rolls of wrapping paper

A = Total amount earned

A = 5 + 1.75r

Equation that represents the total amount A (in dollars) you have after selling r rolls of wrapping paper is

A = 5 + 1.75r

3 0
3 years ago
Other questions:
  • What is Processor to Memory Mismatch problem?
    15·1 answer
  • There are three types of value for money. Which of the following is not a method of value?
    14·1 answer
  • 1. Consider a direct-mapped cache that can accommodate 8Mbytes from a main memory, that uses a 32-bit address and 32-byte blocks
    5·1 answer
  • Text can be easily moved from one location to another using _____.
    15·1 answer
  • Assume you have an Access database with five different tables, including various pieces of information about your client base. Y
    9·1 answer
  • A software update is also referred to as what?
    15·2 answers
  • A programmer has an idea to use just one language for the content, structure, and style of web pages. What might be a problem wi
    11·1 answer
  • if a second system failure occurs while the first recovery is in progress, what needs tobe done after the system recovers for th
    11·1 answer
  • Select the correct answer.
    7·2 answers
  • Does anyone know this? Can someone please help me? I’ll give brainliest!!
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!