Question: write some functions for a knock-knock joke Create a C++ file called joke.cpp and implement the three functions opening(), setup() and punchline() specified in the

write some functions for a knock-knock joke

Create a C++ file called joke.cpp and implement the three functions opening(), setup() and punchline() specified in the header file joke.h

source code:

Joke.h:

#ifndef _JOKE_H_

#define _JOKE_H_

#include using namespace std ;

string opening( ) ;

string setup() ;

string punchline() ;

#endif

Driver.cpp:

#include

#include

#include "joke.h"

using namespace std ;

int main() { cout << opening() << endl ;

cout << "Who's there?" << endl ;

cout << setup() << endl ;

cout << setup() << ", who???" << endl ;

cout << punchline() << endl ;

return 0 ; }

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 Databases Questions!