Skip to content

Instantly share code, notes, and snippets.

@bhargavkulk
Created December 22, 2018 14:13
Show Gist options
  • Save bhargavkulk/aa6320d07ef1d79c31d40236ef051a23 to your computer and use it in GitHub Desktop.
Save bhargavkulk/aa6320d07ef1d79c31d40236ef051a23 to your computer and use it in GitHub Desktop.
#include <iostream.h>
#include <conio.h>
void display_str_array(const char* arr[], int n) {
for(int i = 0; i < n; i++) {
cout << arr[i] << endl;
}
}
void main() {
clrscr();
const char* names[] = {"James", "Jonah", "Jamison"};
display_str_array(names, 3);
getch();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment