|
From: Szentpali J. <ia...@ea...> - 2008-01-07 17:32:15
|
Hi,
I am very new to C++. I only did VB programming... mostly. I am having
some trouble with some C++ code. Could someone help me understand what
the following means:
--- start ---
typedef DWORD(*FUNCPTR)(BYTE);
DWORD ulWorkRandomNum;
char *arr;
int nIndex;
...
arr [2 * nIndex] = 'A' + (((char *) &ulRandomNum) [nIndex] & 0x0f);
--- end ---
I am having trouble with "translating" (understanding) the
((char *) &ulRandomNum) [nIndex]
part. I mean [nIndex] referes to the elemnt of which array :O
--
Szentpáli János
|