Hungarian notation is quite simple.
It involves pre-pending your descriptive variable name with a lower case character or short string that tells you the type of the variable.
So:
Global variables outside setup() and loop(): 'g_', e.g. int g_nPinNum (this is a personal HN customization that I use)
Class (or struct) data members: 'm_', e.g. int m_nPinNum
This is particularly handy with set(...) functions in your class
E.G. void setPinNum(const int nPinNum)
{
m_nPinNum = nPinNum;
}
If you decide you need to change the descriptive part of the name then it is easy to do in one
operation with text search and replace.
Any array: 'array' or 'arry', e.g. int arrayPins[6];
Character array string: 'sz', e.g. char szName[9];
Arduino String object: 'str', e.g. String strName;
Any pointer variable: 'p', e.g. int *pData = NULL;
bool: 'b', e.g. bool bFlag = false;
char: 'c', e.g. char cCh = 0;
int8_t / uint8_t / byte: 'n', e.g. uint8_t nPinNum = 1;
int16_t / uint16_t / int / unsigned: 'n', e.g. uint16_t nData = 1;
int32_t / uint32_t / long / long unsigned: 'n', e.g. uint32_t nLastMillis = 0;
Now you can extend the integers a little if you find it useful, but it will also mean changing your variable names if you change its data type. I don't bother myself and find 'n' for all of them adequate.
uint8_t / byte: 'u8', e.g. uint8_t u8PinNum = 1;
int8_t: 'n8', e.g. int8_t n8PinNum = 1;
uint16_t / unsigned / unsigned int: 'u16', e.g. uint16_t u16Data = 1;
int16_t / int: 'n16', e.g. int16_t n16Data = 1;
uint32_t / long unsigned: 'u32', e.g. uint32_t nLastMillis = 1;
int32_t, long: 'n32', e.g. int32_t nLastMillis = 1;
Now where it is really useful in situations like this:
FirstName + Surname + Age + StudentNumber
Now if you came back to this code 12 months later you might not remember what was going on here.
'FirstName' and 'Surname' are probably string. But what is 'Age'? Is it a string too or is it an object? And what about StudenNumber? Is it a String, a number or some sort of object?
But if you did this instead then it becomes perfectly clear.
strFirstName, + strSurname + szAge + strStudentNumber
It is string concatenation where the first two are Arduino String objects and the last two are regular 'C' or char array strings.
Hungarian notation can also tell you rather a lot about a function as in this example:
String strDetails = formatStudent(strSurname, strFirstName, szAge, szStudentNumber);
Please note that descriptive variable names and Hungarian notation don't have to be mutually exclusive, there is nothing stopping you from using both naming conventions in a complementary way.