Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Fundamentals Of Database System

Authors: Elmasri Ramez And Navathe Shamkant

7th Edition

978-9332582705

More Books

Students also viewed these Databases questions

Question

What is the difference between rational and real zeros?

Answered: 1 week ago

Question

What is the growth rate of GDP per capita?

Answered: 1 week ago