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
Mice21 [21]
3 years ago
11

Jasmine is writing a shopping app. She has created a variable to keep track of the number of items in the shopping cart. Everyti

me someone clicks the "addItemButton", she would like the variable to increase by 1. What code should Jasmine insert where it says in order for her app to work?a. cart total = 1.b. cart total + 1.c. cart total = cartTotal +1.d. var cart total = cartTotal + 1.e. var cart total + 1.
Computers and Technology
1 answer:
Gemiola [76]3 years ago
6 0

Answer:

b. cart total + 1

Explanation:

A. cart total=1 do increment the total with every 1 click here, it only 're-assigns cart total with value 1 for every click, hence it's always 1.

B. In every click, 1 is always added to the previous value of cart total, like addItemButton(cart total+1) or so.

C. This would have worked too if "cart total" and "cartTotal" where of same type.

D. cart total is just being initially defined here.

E. Likewise here, var shows that cart total has just only been declared.

You might be interested in
Assume that x is a variable that has been declared as an int and been given a value. Assume that twice is a method (in the same
Anastasy [175]

Answer:

Arrays are indexed from 0 in pretty much every language, except stupid Microsoft languages.

Lets say that ARR_SIZE is 5 for example.

So you have an array of 5 elements. They are indexed from 0 - 4.

arr[0] // First element

arr[4] // Last element

Therefore arr[ ARR_SIZE -1 ] is the last element of the array.

That's why for loops to iterate through arrays are wrote like:

for(int i = 0; i < ARR_SIZE; ++i)

4 0
3 years ago
In the current situation, how do you access information as a student? How will you integrate the use of ICT in your daily life a
3241004551 [841]

Answer:

Explanation:

As a computer science student information is accessed in every possible way. This can be through a local school lan network, mobile devices, e-mail, etc. All of these help information flow to and from various people and makes obtaining this information incredibly simple as a student. Especially in the field of computer science, I need to integrate as many ICT devices with me in my everyday life, to send emails, check calendar updates, research information on the web, check school reports, and even speak with clients.

3 0
3 years ago
It is not important to keep financial records since they can all be found online.
aleksandr82 [10.1K]

Answer:

False

Explanation:

Due to the fact that financial records can be erased. Also, I believe it is a law to keep financial records when doing business but I'm not too sure.

6 0
4 years ago
Read 2 more answers
Which element of the word window is to the right of the screen
sesenic [268]

Answer: task pane

Using the task pane When opened, the task pane will appear on the right side of the Word window. The task pane provides easy access to commonly used menus, buttons, and tools.

Hope this helps....... Stay safe and have a Merry Christmas!!!!!!!!! :D

7 0
3 years ago
Read 2 more answers
When Brittany practiced her presentation, she gave a trusted adult a presentation checklist to use to critique her each time she
alexdok [17]
Track her improvement.

She can compare the checklists from each time she has practiced to see what she needs to work on.
5 0
3 years ago
Other questions:
  • A ____________would be a misconfiguration of a system that allows the hacker to gain unauthorized access, whereas a_____________
    12·1 answer
  • What is TRUE about the following array?
    15·1 answer
  • There are two different perspectives in terms of how programs are delivered for different ethnic groups. If an agency offers dif
    14·1 answer
  • Which entity has the principal responsibility to control the execution of processes?
    14·1 answer
  • What does the clone tile command do?
    15·2 answers
  • Module 7: Input and Output, 7-13d: Checkpoint
    15·1 answer
  • Go in my discord server Code is . (CebjBXN)​
    10·2 answers
  • How can you tell the difference between subnet addresses and interface addresses?
    13·1 answer
  • You have a large text file of people. Each person is represented by one line in the text file. The line starts with their ID num
    5·1 answer
  • The first page of a website is what?​
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!