Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using C++: Given an arbitrary ransom note, consisting of 15 - 20 words and several magazines, write a function that will return a true, if

Using C++:

Given an arbitrary ransom note, consisting of 15 - 20 words and several magazines, write a function that will return a true, if the ransom note can be constructed from the words in the magazines, otherwise it will return a false. Each word in the magazines can only be used once in your ransom note. The algorithm should work efficiently, such as, utilizing hash tables for storing and looking up strings. An example hash function maybe the sum of the ascii values of all the characters in the string, modulus an appropriate positive integer. Utilize the built in string class, and some of its methods. For testing the code, utilize the ransom note and the magazines provided on the Blackboard in les RansomNote.dat, Magazine1.dat, Magazine2. dat, Magazine3.dat, Magazine4.dat, Magazine5.datand Magazine6.dat.

---->RansomeNote.dat:

We have your cat in our possession. If you do not pay us $10,000, we will delete her Twitter Account.

---->Magazine1.dat:

There are two slightly different meanings of safety. For example, home safety may indicate a building's ability to protect against external harm events (such as weather, home invasion, etc.), or may indicate that its internal installations (such as appliances, stairs, etc.) are safe (not dangerous or harmful) for its inhabitants.

Discussions of safety often include mention of related terms. Security is such a term. With time the definitions between these two have often become interchanged, equated, and frequently appear juxtaposed in the same sentence. Readers unfortunately are left to conclude whether they comprise a redundancy. This confuses the uniqueness that should be reserved for each by itself. When seen as unique, as we intend here, each term will assume its rightful place in influencing and being influenced by the other.

Safety is the condition of a steady state of an organization or place doing what it is supposed to do. What it is supposed to do is defined in terms of public codes and standards, associated architectural and engineering designs, corporate vision and mission statements, and operational plans and personnel policies. For any organization, place, or function, large or small, safety is a normative concept. It complies with situation-specific definitions of what is expected and acceptable.

Using this definition, protection from a homes external threats and protection from its internal structural and equipment failures (see Meanings, above) are not two types of safety but rather two aspects of a homes steady state. In the world of everyday affairs, not all goes as planned. Some entitys steady state is challenged. This is where security science, which is of more recent date, enters. Drawing from the definition of safety, then: Security is the process or means, physical or human, of delaying, preventing, and otherwise protecting against external or internal, defects, dangers, loss, criminals, and other individuals or actions that threaten, hinder or destroy an organizations steady state, and deprive it of its intended purpose for being. Using this generic definition of safety it is possible to specify the elements of a security program.

Limitations Safety can be limited in relation to some guarantee or a standard of insurance to the quality and unharmful function of an object or organization. It is used in order to ensure that the object or organization will do only what it is meant to do. It is important to realize that safety is relative. Eliminating all risk, if even possible, would be extremely difficult and very expensive. A safe situation is one where risks of injury or property damage are low and manageable.

----->Magazine2.dat:

The base currency of the United States is the U.S. dollar. Since 1946 it has been printed in seven denominations: $1, $2, $5, $10, $20, $50, and $100. Previously there have also been five larger denominations: $500, $1,000, $5,000, and $10,000 were printed for general use (in large transactions), and a $100,000 bill for certain internal transactions.

Overview and history Large-denomination currency (i.e., banknotes with a negotiable face value of $500 or higher) had been used in the United States since the late 18th century. The first $500 note was issued by the Province of North Carolina, authorized by legislation dated May 10, 1780. Virginia quickly followed suit and authorized the printing of $500 and $1,000 notes on October 16, 1780 and $2,000 notes on May 7, 1781. High-denomination treasury notes were issued, for example during the War of 1812 ($1,000 notes authorized by an act dated June 30, 1812). During the American Civil War Confederate currency included $500 and $1,000 notes. During the Federal banknote issuing period (1861 to present), the earliest high-denomination notes included three-year Interest-bearing notes of $500, $1,000, and $5,000, authorized by Congress on July 17, 1861.[8] In total, 11 different types of U.S. currency were issued in high-denomination notes across nearly 20 different series dates. The obverse of United States banknotes generally depict either historical figures, allegorical figures symbolizing significant concepts (e.g., liberty, justice), or a combination of both. The reverse designs range from abstract scroll-work with ornate denomination identifiers to reproductions of historical art works.

Public versus institutional use Series 1934 Gold certificates ($100, $1,000, $10,000 and $100,000) were issued after the gold standard was repealed and gold was compulsorily confiscated by order of President Franklin Roosevelt on March 9, 1933 (see United States Executive Order 6102). Thus the Series 1934 notes were used only for intra-government (i.e., Federal Reserve Bank) transactions and were not issued to the public. This series was discontinued in 1940. The Series 1928 Gold certificate reverse was printed in black and green. See History of the United States dollar.

Passive retirement Although they are still technically legal tender in the United States, high-denomination bills were last printed on December 27, 1945, and officially discontinued on July 14, 1969, by the Federal Reserve System, supposedly due to 'lack of use'. The $5,000 and $10,000 effectively disappeared well before then. The Federal Reserve began taking high-denomination currency out of circulation (destroying large bills received by banks) in 1969. As of May 30, 2009, only 336 $10,000 bills were known to exist; 342 remaining $5,000 bills; and 165,372 remaining $1,000 bills. Due to their rarity, collectors often pay considerably more than the face value of the bills to acquire them. Some are in museums in other parts of the world.

---->Magazine3.dat

Twitter is an online news and social networking service where users post and interact with messages, "tweets," restricted to 140 characters. Registered users can post tweets, but those who are unregistered can only read them. Users access Twitter through its website interface, SMS or a mobile device app. Twitter Inc. is based in San Francisco, California, United States, and has more than 25 offices around the world.

Twitter was created in March 2006 by Jack Dorsey, Noah Glass, Biz Stone, and Evan Williams and launched in July, whereby the service rapidly gained worldwide popularity. In 2012, more than 100 million users posted 340 million tweets a day, and the service handled an average of 1.6 billion search queries per day. In 2013, it was one of the ten most-visited websites and has been described as "the SMS of the Internet". As of 2016, Twitter had more than 319 million monthly active users. On the day of the 2016 U.S. presidential election, Twitter proved to be the largest source of breaking news, with 40 million tweets sent by 10 p.m. (Eastern Time) that day.

Verified accounts The official Twitter profile of Twitter, Inc. The blue check mark right of the profile name confirms that it is a verified account. A verified Twitter Account formally validates the identity of the person or company that owns the accountthe aim of the "verified" status is to prove that a real-world person or company is not being impersonated, through the placement of a small blue checkmark by the top-right corner of a user's page, or next to the username in the platform's Search function. Twitter is responsible for assigning the blue checkmark, and it is frequently applied to the accounts of notable people in politics, music, movies, business, fashion, government, sports, media, and journalism.

The owners of verified accounts can also access additional features that are not available to standard Twitter-account holders. These features include: The ability to choose how their notifications and mentions are presented. Since verified accounts typically receive a lot of followers, account holders can filter these notices based on whether or not they are from verified accounts. The ability to view information about their followers and their involvement on Twitter. The ability to receive direct messages from all followers or only selected followers.

On December 14, 2010, the United States Department of Justice issued a subpoena directing Twitter to provide information for accounts registered to or associated with WikiLeaks. Twitter decided to notify its users and said in a statement, "... it's our policy to notify users about law enforcement and governmental requests for their information, unless we are prevented by law from doing so."

---->Magazine4.dat

While anyone can edit articles, to keep things manageable, only administrators can delete them. Note that removing all text from a page does not delete it, it just leaves a blank page, which is discouraged as it is confusing to readers. The text can be restored from the page history.

This page explains how to ask for an article to be deleted from Wikipedia. For all the gritty details, see the deletion policy. Bear the following things in mind:

It is better to improve an article than to delete it for not being good enough.

An article that looks inappropriate may simply have been tampered with; you can fix this by reverting it to the better, previous version.

If the article duplicates another, you can redirect it to the other one; there's no need for it to be deleted first.

It's polite to let the article's author know that you are asking for it to be deleted; you can find them in the page history.

Pages you created yourself If you create a page yourself and then change your mind, just add the text to the top of it; it will be deleted shortly afterward. If other contributors have edited the page, however, this usually won't be done; use one of the methods explained below.

Pages which are not articles Not all pages in Wikipedia are encyclopedia articles. Those that begin with a prefix such as "Wikipedia:" or "User:" are used for organizing the project, so are not considered part of the encyclopedia. Different rules apply to these pages; you can't use the "proposed deletion" option mentioned below, and deletion discussions take place in different places. If you think one of these pages should be deleted, see the full Guide to deletion, which has more detailed instructions on what to do.

Speedy deletion In certain limited circumstances, an article can be deleted on sight with no further discussion. These limited circumstances are called the criteria for speedy deletion, and pages that meet them are usually removed quickly. If you find one, you can mark it for deletion by adding the text {{delete| reason }} to the top of the page, replacing "reason" with the reason it should be deleted. Most articles do not meet the criteria, however, so check carefully before doing this.

---->Magazine5.dat

Possession acquired by consent Most property possessed is obtained with the consent of someone else who possessed it. They may have been purchased, received as gifts, leased, or borrowed. The transfer of possession of goods is called delivery. For land, it is common to speak of granting or giving possession. A temporary transfer of possession is called a bailment. Bailment is often regarded as the separation of ownership and possession. For example, the library continues to own the book while you possess it and will have the right to possess it again when your right comes to an end. A common transaction involving bailment is a conditional sale or hire-purchase, in which the seller lets the buyer have possession of the thing before it is paid for. The buyer pays the purchase price in installments and, when it is fully paid, ownership of the thing is transferred from seller to buyer.

Possession acquired without consent It is possible to obtain possession of a thing without anyone else's consent. First, you might take possession of something which has never been possessed before. This can occur when you catch a wild animal; or create a new thing, such as a loaf of bread. Secondly, you might find something which someone else has lost. Thirdly, you might take something from another person without their consent. Possession acquired without consent is a property right which the law protects. It gives rise to a right of possession which is enforceable against everyone except those with a better right to possession.

--->Magazine6.dat

Julia Hall Bowman Robinson (December 8, 1919 July 30, 1985) was an American mathematician best known for her work on decision problems and Hilbert's tenth problem.

Hilbert's tenth problem asks for an algorithm to determine whether a Diophantine equation has any solutions in integers. A series of results developed in the 1940s through 1970 by Robinson, Martin Davis, Hilary Putnam, and Yuri Matiyasevich resolved this problem in the negative; that is, they showed that no such algorithm can exist. George Csicsery produced and directed a one-hour documentary about Robinson titled Julia Robinson and Hilbert's Tenth Problem, that premiered at the Joint Mathematics Meeting in San Diego on January 7, 2008. Notices of the American Mathematical Society printed a film review and an interview with the director. College Mathematics Journal also published a film review.

Using C++ and hash table and ascii table, we need to use all files RansomNote.dat, Magazine1.dat, Magazine2.dat, Magazine3.dat, Magazine4.dat, Magazine5.dat and Magazine6.dat. The whole code(answer) is needed, not just part of it.

If you need Ransomnote and magazine files, please write the email address.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions