Hdu 2317 Nasty Hacks

Source: Internet
Author: User

Hdu 2317 Nasty Hacks

Q: The income from non-advertising is r, the income from advertising is e-c (expected income-advertising fee), and the water question is not explained...

 

 

# Include
 
  
Using namespace std; int main () {int n, r, e, c; cin> n; while (n --) {cin> r> e> c; if (r> e-c) {cout <"do not advertise" <
  
   

 

 

 

Nasty Hacks Nasty hacker Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission (s): 2863 Accepted Submission (s): 2233Problem DescriptionYou are the CEO of Nasty Hacks Inc ., a company that creates small pieces of malicious software which teenagers may use to fool their friends. you are the CEO of a hacker Company, which creates small pieces of malware. Teenagers may use it to fool their friends. The company has just finished their first product and it is time to sell it. The company has finished its first product and it is time to sell it. You want to make as much money as possible and consider advertising in order to increase sales. You want to make as much money as possible, whether to consider advertising to increase sales. You get an analyst to predict the expected revenue, both with and without advertising. You have to analyze the expected earnings for both advertising and non-advertising. You now want to make a demo-as to whether you shocould advertise or not, given the expected revenues. now You have to make a decision, do it or not, and output additional benefits. InputThe input consists of n cases, and the first line consists of one positive integer giving n. the input contains multiple groups of test events. The first line is a positive integer n, The next n lines each contain 3 integers, r, e and c. the next n rows have three integers: r, e, and c. the first, r, is The expected revenue if you do not advertise. if you do not advertise, r indicates the expected earnings; the second, e, is the expected revenue if you do advertise, and the third, c, is the cost of advertising. if you advertise, e table Shows the expected earnings, and c indicates the advertising cost. You can assume that the input will follow these restrictions:-106 ≤ r, e ≤ 106 and 0 ≤ c ≤ 106. you can think that the input data is in the following range:-106 ≤ r, e ≤ 106 and 0 ≤ c ≤ 106. OutputOutput one line for each test case: "advertise", "do not advertise" or "does not matter". each test event is output in a separate line. "Advertise", "do not advertise" or "does not matter ". Presenting whether it is most profitable to advertise or not, or whether it does not make any difference. Which of the three is the most advantageous. Sample Input
30 100 70100 130 30-100 -70 40

Sample Output
advertisedoes not matterdo not advertise

Source Nordic 2006

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.