Answer:
Check the explanation
Explanation:
(a)
# We need to try all options(TRUE/FALSE) of all the Variables
# to find the correct arrangement.
permutations <- permutate(0,1,n) [Find all permutions O(2^n)]
for permutation in permutations:
for X in variables:
if(permutation[i] == 1)
substitute(H,X,true)
else
substitute(H,X,false)
if(satisfiable(H)) return permutation
increment i
Answer:
The right approach will be "PSH".
Explanation:
- The PSH flag seems to be an acceptable solution through TCP which always encourages the submit implementation to immediately transfer data but only whenever the buffer isn't complete.
- The implementation helps to formulate this same flag towards true for something like the connection, as well as TCP will instantly begin transmitting the relevant information.
Answer:
#include <iostream>
#include <cstring>
using namespace std;
void replacePeriod(char* phrase) {
int i = 0;
while(*(phrase + i) != '\0')
{
if(*(phrase + i) == '.')
*(phrase + i) = '!';
i++;
}
}
int main() {
const int STRING_SIZE = 50;
char sentence[STRING_SIZE];
strcpy(sentence, "Hello. I'm Miley. Nice to meet you.");
replacePeriod(sentence);
cout << "Updated sentence: " << endl;
cout << sentence << endl;
return 0;
}
Explanation:
- Create a function called replacePeriod that takes a pointer of type char as a parameter.
- Loop through the end of phrase, check if phrase has a period and then replace it with a sign of exclamation.
- Inside the main function, define the sentence and pass it as an argument to the replacePeriod function.
- Finally display the updated sentence.
Answer: create a custom template
Explanation:
Since Sarah is having a hard time finding a template for her advertising business that she may be able to use at a later date and also make it available to her colleagues, her best option will be to create a custom template.
Creating a custom template will ensure that she makes the template based on her requirements and can tailor it specifically to her needs which then makes it unique.