97 lines
1.8 KiB
C++
97 lines
1.8 KiB
C++
#include <iostream>
|
|
#include <string>
|
|
using namespace std;
|
|
|
|
|
|
// Mini Project 1
|
|
/*
|
|
Prompt for 3 numbers (doubles)
|
|
Print out after each number
|
|
Find the mean of the 3 numbers
|
|
Print that as 'Average is {result}'
|
|
*/
|
|
|
|
//int main()
|
|
//{
|
|
// double input1 = 0, input2 = 0, input3 = 0;
|
|
//
|
|
// cout << "Enter a real number: " << endl;
|
|
// cin >> input1;
|
|
//
|
|
// cout << "Enter a second real number: " << endl;
|
|
// cin >> input2;
|
|
//
|
|
// cout << "Enter a final real number: " << endl;
|
|
// cin >> input3;
|
|
//
|
|
// double result = (input1 + input2 + input3) / 3;
|
|
// cout << "Average is " << result << endl;
|
|
//
|
|
// return 0;
|
|
//}
|
|
|
|
// Mini Project 2
|
|
|
|
int main()
|
|
{
|
|
string inputs[11];
|
|
|
|
cout << "Enter an Adjective: " << endl;
|
|
getline(cin, inputs[0]);
|
|
|
|
cout << "Enter a girl's name: " << endl;
|
|
getline(cin, inputs[1]);
|
|
|
|
cout << "Enter another Adjective: " << endl;
|
|
getline(cin, inputs[2]);
|
|
|
|
cout << "Enter an Occupation: " << endl;
|
|
getline(cin, inputs[3]);
|
|
|
|
cout << "Enter a Place Name: " << endl;
|
|
getline(cin, inputs[4]);
|
|
|
|
cout << "Enter an item of clothing: " << endl;
|
|
getline(cin, inputs[5]);
|
|
|
|
cout << "Enter a hobby: " << endl;
|
|
getline(cin, inputs[6]);
|
|
|
|
cout << "Enter another Adjective: " << endl;
|
|
getline(cin, inputs[7]);
|
|
|
|
cout << "Enter another Occupation: " << endl;
|
|
getline(cin, inputs[8]);
|
|
|
|
cout << "Enter A Boy's Name: " << endl;
|
|
getline(cin, inputs[9]);
|
|
|
|
cout << "Enter a Man's Name: " << endl;
|
|
getline(cin, inputs[10]);
|
|
|
|
cout << "There once was a "
|
|
<< inputs[0]
|
|
<< " girl named "
|
|
<< inputs[1]
|
|
<< " who was a "
|
|
<< inputs[2]
|
|
<< " "
|
|
<< inputs[3]
|
|
<< " in the Kingdom of "
|
|
<< inputs[4]
|
|
<< ". She loved to wear "
|
|
<< inputs[5]
|
|
<< " and "
|
|
<< inputs[6]
|
|
<< ". She wanted to marry the "
|
|
<< inputs[7]
|
|
<< " "
|
|
<< inputs[8]
|
|
<< " named "
|
|
<< inputs[9]
|
|
<< " but her father, King "
|
|
<< inputs[10]
|
|
<< " forbid her from seeing him.";
|
|
|
|
return 0;
|
|
} |