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
Ilya [14]
3 years ago
8

Suppose that in a 00-11 knapsack problem, the order of the items when sorted by increasing weight is the same as their order whe

n sorted by decreasing value. Give an efficient algorithm to find an optimal solution to this variant of the knapsack problem, and argue that your algorithm is correct.
Computers and Technology
1 answer:
frosja888 [35]3 years ago
8 0

Answer:

Following are the response to the given question:

Explanation:

The glamorous objective is to examine the items (as being the most valuable and "cheapest" items are chosen) while no item is selectable - in other words, the loading can be reached.

Assume that such a strategy also isn't optimum, this is that there is the set of items not including one of the selfish strategy items (say, i-th item), but instead a heavy, less valuable item j, with j > i and is optimal.

As W_i < w_j, the i-th item may be substituted by the j-th item, as well as the overall load is still sustainable. Moreover, because v_i>v_j and this strategy is better, our total profit has dropped. Contradiction.

You might be interested in
You have posted some embarrassing photos of a friend onto the Internet. After
e-lub [12.9K]

Answer:

C

Explanation:

4 0
3 years ago
The ____ job functions and organizational roles focus on protecting the organization's information systems and stored informatio
dalvyx [7]

Answer:

Option B i.e., Information security management and professionals is the correct option.

Explanation:

They performs the work duties and operational responsibilities focus on supporting the information systems of the corporation and information stored against threats. IMS is a set of principles and protocols for the structured handling of sensitive information within an enterprise. An ISMS helps to eliminate risks and maintain continuity of operation through pro-actively minimizing the effects of a breach of security.

5 0
4 years ago
Write a program that prints the question " Do youwant to continue? " and reads a user input. if the userinput is " Y ", " OK", o
Nataly_w [17]

Answer:

#include <bits/stdc++.h>

using namespace std;

int main() {

   string in;//string in for taking input...

   cout<<"Do you want to continue ?"<<endl;

   getline(cin,in);//taking input from the user...

   if(in=="y"||in=="Y"||in=="yes"||in=="OK"||in=="Why not?")//conditions..

   cout<<"OK"<<endl;

   else if(in=="No")

   cout<<"terminating"<<endl;

   else

   cout<<"Bad input"<<endl;

return 0;

}

Explanation:

I have taken a string in.

Then taking input from user.

Checking the conditions using if else if ladder.

7 0
3 years ago
What is the typical name of the input file for the compiler?
lys-0071 [83]

Answer:

jpg or jenp or png

Explanation:

6 0
4 years ago
By the 1970s, the acceleration of airplane travel led to fears that an epidemic would leapfrog the globe much faster than the pa
kramer

Answer:

b. the HIV infection.

Explanation:

Around the 1970s, an increase in the use of airplane travel led to fears that an epidemic would leapfrog the globe much faster than the pandemics such as tuberculosis, leprosy, smallpox, trachoma, anthrax, scabies, etc., that were evident during the Middle Ages, fears that were later confirmed by the worldwide spread of the HIV infection, beginning in the 1970s in the United States of America.

STD is an acronym for sexually transmitted disease and it can be defined as diseases that are easily transmissible or contractable from another person through sexual intercourse. Thus, STD spread from an infected person to an uninfected person while engaging in unprotected sexual intercourse. Some examples of STDs are gonorrhea, chlamydia, syphilis, HIV, etc.

HIV is an acronym for human immunodeficiency virus and it refers to a type of disease that destabilizes or destroy the immune system of a person, thus, making it impossible for antigens to effectively fight pathogens.

Generally, contracting STDs has a detrimental effect to a patient because it causes an opening (break) or sore in the body of the carrier (patient) and as such making them vulnerable to diseases that are spread through bodily fluids e.g human immunodeficiency virus (HIV), Hepatitis, staphylococcus, AIDS, etc.

4 0
3 years ago
Other questions:
  • If people have humility, they don’t tend to see themselves as overly or more important than others. True False
    13·1 answer
  • In the context of information systems, which of the following is a disadvantage of prototyping? a. A prototype is more difficult
    8·1 answer
  • Create a class called Toddler that inherits from a class called Parent. (Note that Parent has already been defined elsewhere, so
    8·2 answers
  • When a third variable is included in an analysis and that third variable changes the relationship between the independent variab
    13·1 answer
  • A programmer, or software developer, is a person with the training and skills necessary to ____________ computer programs.
    13·1 answer
  • How do i make a profile picture <br> REALLY URGENT I NEED IT NOW!!!
    8·2 answers
  • 1. Define Validation Rule
    14·1 answer
  • What is the number system that uses only the numbers 0 and 1?
    8·1 answer
  • The purpose of a flowchart is similar to the purpose of pseudocode.<br> True<br> False
    5·2 answers
  • Indonesia is planning to move its capital from Jakarta to the island of Borneo in the hope that the burden of congestion, regula
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!