[solved] – Question 86442
Enter a name: Grace
Enter an adjective: stinky
Enter an adjective: blue
Enter an adverb: quietly
Enter a food: soup
Enter another food: bananas
Enter a noun: button
Enter a place: Paris
Enter a verb: jump
Grace was planning a dream vacation to Paris.
Grace was especially looking forward to trying the local
cuisine, including stinky soup and bananas.
Grace will have to practice the language quietly to
make it easier to jump with people.
Grace has a long list of sights to see, including the
button museum and the blue park.
Expert Answer
[solved] – Question 86461
A king has 100 servants, then he decides that he wants only one servant:
He numbers them from 1 to 100 and puts them in a circle, gives servant no.1 a sword and begins a round: 1 kills 2 and passes the sword to 3, 3 kills 4 and moves to 5 and so on …
What is the last remaining servant ? We have to write a small program that will solve it & present the solution.
Expert Answer
[solved] – Question 86516
Prepare a worksheet that allows the user to enter ONLY these fields: Start Time and End Time per day on a 5 day workweek (10 cells) and Hourly Wage (1 cell), Total Hours Worked (1 cell), and Total Earnings (1 cell). So there should ONLY be 13 data entry fields for the user. Each of those fields should have a title, so there should be an additional 13 title cells explaining each data cell. Make sure that the title fields are properly labeled. So, there should be 26 cells used in total.
Expert Answer
[solved] – Question 86593
I am currently working on a program set and I was wondering if you could answer my question.
I have come across std::string letterOccurence(); and
I have done my code to let the program run; this is the code below: string str;
//cin>>str;
getline(cin,str);
char checkCharacter = ‘a’;
int count = 0;
for (int i = 0; i < str.size(); i++)
{
if (str[i] == checkCharacter)
{
++ count;
}
++checkCharacter +1;
}
cout << “Number of ” << checkCharacter << ” = ” << count;
return 0;
Apparently I should use a 2 dimensional array but I am stuck. Please help!
Expert Answer
[solved] – Question 86644
Implement the basic recursive implementation of Fibonacci number function and find the largest Fibonacci number that your computer can compute. The algorithm is as follows:
int Fib(int n)â¨{⨠if(n<2) return n;⨠return Fib(n-1) + Fib(n-2);â¨}
Expert Answer
[solved] – Question 86645
Implement quicksort using by choosing the following two ways of picking the pivot:
a.Randomly
b.Median-of-3
Now find out which implementation is running faster by sorting a huge size (10 million integers) array. Fill this array with random numbers and then sort it using both above schemes.
Expert Answer
[solved] – Question 86646
Multiply the following two matrices using Strassenâs algorithm. Do it manually, that is, using paper and pencil by hand. Show clearly all the intermediate steps.
A = 3 2 1 0
5 6 2 7
7 6 5 2
1 2 3 5
B= 5 6 7 1
1 3 2 0
5 6 7 1
2 3 9 0
Expert Answer
[solved] – Question 86665
c[0] = 11
c[1] = 22
c[2] = 33
c[3] = 44
c[4] = 55
Press any key to continue . . .
*/
#include <iostream>
using namespace std;
void main()
{
int a[5] = {1, 2, 3, 4, 5};
int b[5] = {10, 20, 30, 40, 50};
int c[5];
// now we meant to add a & b and put result in c
c = a + b;// is this allowed? if not what is the alternative
for(int i = 1; i <= 5; i++)
printf(“nc[“%i”] = %i”, i, c[i]);
printf(“nn”);
system(“pause”);
return;
}
Expert Answer
[solved] – Question 86724
For this lab you will find the area of an irregularly shaped room with the shape as shown above.
Ask the user to enter the values for sides A, B, C, D, and E and print out the total room area.
Remember the formula for finding the area of a rectangle is length * width and the area of a right triangle is 0.5 * the base * height.
Please note the final area should be in decimal format.
Sample Run
Expert Answer
[solved] – Question 8679
How can I write a program that calculates : e^x = 1+x/1!+x^2/2!+x^3/3!+…
Expert Answer

