Simple Windows Application naming

Source: Internet
Author: User

1 . The type name and function name are combined with words beginning with uppercase letters. For example:

class Node;                        // class name class Leafnode;                    // class name void Draw (void);                // Name of function void SetValue (int value);        // Name of function

2 . The variable name and parameter name are combined with the first letter lowercase word and the words that follow the first letter of the word. For example:

BOOL Flag; int DrawMode;

3, symbolic constants and macro names are combined with all uppercase words, and separated by a single underline between the words, note that it is best not to use underscores. For example:

Const int  - ; Const int 1024x768;

4 . Prefix the static variable with s_, prefix the global variable with the g_, and prefix the data members of the class with m_. For example:

Static int S_initvalue; int g_howmanypeople;

Simple Windows Application naming

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.