Question: Heres another random fact that Im going to share about myself. I went to NorthHollywood High School ( NHHS ) Highly Gifted Magnet ( HGM

Heres another random fact that Im going to share about myself. I went to NorthHollywood High School (NHHS) Highly Gifted Magnet (HGM) for school. You probablyare wondering what is a Highly Gifted Magnet and how does one get there? You takean IQ test and if you get at least a 150(which is genius level), you are eligible to get in.Believe it or not, at one point, I tested to that level. (That is probably before all of theseadult beverages got into my system, probably lowering that mark. =]) Well, the reason Imention this is because we recently just celebrated our 25 year class reunion! Twenty-five years is more time than some of you reading this have been alive, which makes mea fossil to you at this point. (Yes, your professor has jokes and is self-deprecating. =])The thing about a reunion is that it is a big game of trying to figure out who is doing whatnow, what happened to a certain person, and what are the stories and memories thatyou take from that time. Its a fun game indeed.There are also other games that you can play. Take word games, like Scrabble andWords with Friends, that require rearranging a combination of letters to make a word.This type of arrangement is generally referred to as an anagram, while it's known as apermutation in mathematics. This assignment will give you some experience thinkingabout and writing recursive functions. Write a C++ program that searches for"anagrams" in a dictionary. An anagram is a word obtained by scrambling the letters ofsome string. For example, the word "pot'' is an anagram of the string "otp." A samplerun of the program is given below. Your output does not have to be formatted exactlythe same as that shown in the sample, but it should be in a similar style. You can usewords.txt as your dictionary file and anagrams.cpp as an example of a mainprogram.Since the purpose of this assignment is to give you experience using recursion, youmay not use any of C++'s iteration constructs (do, while, for, and goto) or any STLalgorithms (if you have no idea what this means, you're OK). In fact, similar tohomework #2, you may only use the substr() and size()/length() functions in the stringclass. All repetition must be accomplished using recursion. This applies to everyoperation in the program, even file operations. Obviously, you would never write aprogram like this in industry but as an exercise it should be useful to gain experiencewith recursion.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!