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
Volgvan
3 years ago
15

Write an if-else statement for the following: If user_tickets is less than 5, assign 1 to num_tickets. Else, assign user_tickets

to num_tickets. Sample output with input: 3 Value of num_tickets: 1

Computers and Technology
1 answer:
lesya [120]3 years ago
3 0

Answer:

Please find the answer in the attached image.

Explanation:

I wrote this program using JavaScript programming language.

// A function to check tickets

function tickets(user_tickets){

var num_tickets;

if (user_tickets < 5) {

 num_tickets = 1;

 return ('num_tickets: '+ num_tickets);

}

else {

 num_tickets = user_tickets;

 return('num_tickets: '+ num_tickets);

}

}

// Testing the tickets function

// With user_tickets = 3, 5, 8, and 1

console.log(tickets(3));

console.log(tickets(5));

console.log(tickets(8));

console.log(tickets(1));

You might be interested in
_________ is the biggest problem you can face if you don’t identify the scope of your risk management project. Scope creep Nonco
mart [117]

Answer: Scope creep

Explanation:

 Scope creep in the project management basically refers to the uncontrolled development or growth in the project creep. It basically occur when the project scope are not appropriately defined.

It usually involve lack of change in the control system and increase the complexity of the project. It is also has poor requirement analysis.

So, that is why it is the biggest problem we usually face in the project management.

5 0
3 years ago
The letters a, e, i, o and u are the only vowels. Write a function named vowelUseDict() takes a string t as a parameter and comp
Andru [333]

Please specify the programming language.


3 0
4 years ago
Lisa has a section of her document that she would like to include in the index. Which option should Lisa choose?
kupik [55]

Answer:

For including a part of the text within the index, you need to make use of the Mark Entry option. And here you can fill the required information for curating your index, you need to just follow the instruction as required, and you will be fine.

Explanation:

Please check the answer.

8 0
3 years ago
Running the Disk Cleanup utility is a quick way to ________. Group of answer choices defrag your hard drive remove spyware progr
grigory [225]

Answer:

Clear out any garbage file on the drive

Explanation:

7 0
3 years ago
What are the primary benefits of relying on systems development standards?
Sunny_sXe [5.5K]

Answer:

The benefits of relying on System Development Standards is explained below.

Explanation:

There are many benefits of having a Well Defined Systems Development. It helps in having a pre - planned and well defined structure before the project starts. It helps in having a Clear view of the whole project and also each phase of the whole System Development. It helps in having an understanding of cost required and the revenues generated at each phase of the whole system development. It helps in having an understanding of the goal of each phase and procedures need to be followed for that particular goal. It also helps in having the quality checked and the improvements need to be made for the desired quality.

3 0
3 years ago
Other questions:
  • Peter works on a huge database of numerical figures in a worksheet ranging from cell A1 to cell I50. He has to print the workshe
    15·2 answers
  • Alpha Technologies, a newly established company, wants to share information about its work with people all over the world. Which
    9·1 answer
  • Which of the following activities poses the greatest personal cybersecurity risk? A. Making a purchase on an online store that u
    13·1 answer
  • ALGUEM SABE COMO MUDA O NOME DE PERFIL!?!?!? SE SOUBER ME AJUDA!!
    14·1 answer
  • When a project manager can look at the progress towards the goals set, this is considered...?
    11·2 answers
  • What is a feature of audio editing software
    11·1 answer
  • A(n) _______ is a distributed networking architecture, residing on one or more computers, where one program requests a resource
    14·1 answer
  • Wendy had been searching the internet for a great deal on jewelry. While looking at one site, a pop-up was displayed that told h
    11·1 answer
  • What are the two extra registers that the fetch decode execute cycle uses to communicate with memory outside of the chip?
    9·1 answer
  • describe the impact of technology in your life . how does it affects your human relations with other people .​
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!