Skip to content

Instantly share code, notes, and snippets.

@kkabdol
Last active June 23, 2016 02:27
Show Gist options
  • Select an option

  • Save kkabdol/3cdeb740ce288dbfbb9e3e2984c4fb68 to your computer and use it in GitHub Desktop.

Select an option

Save kkabdol/3cdeb740ce288dbfbb9e3e2984c4fb68 to your computer and use it in GitHub Desktop.
Pass By Reference - Char Array
#include <iostream>
using namespace std;
void print( const char ( &UniqueId )[ 40 ] )
{
cout << UniqueId << endl;
}
int main()
{
char UniqueId[ 40 ] = "3b217b81-22ad-4f9b-aeb4-ff0896ba9ad5";
print( UniqueId );
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment