TAILIEUCHUNG - Kỹ thuật lập trình_Module 7

Tham khảo tài liệu 'kỹ thuật lập trình_module 7', công nghệ thông tin, kỹ thuật lập trình phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | Module 7 More Data Types and Operators Table of Contents CRITICAL SKILL The const and volatile CRITICAL SKILL CRITICAL SKILL static CRITICAL SKILL register CRITICAL SKILL CRITICAL SKILL CRITICAL SKILL The Shift CRITICAL SKILL The CRITICAL SKILL The Comma CRITICAL SKILL Compound CRITICAL SKILL Using This module returns to the topics of data types and operators. In addition to the data types that you have been using so far C supports several others. Some of these consist of modifiers added to the types you already know about. Other data types include enumerations and typedefs. C also provides several additional operators that greatly expand the range of programming tasks to which C can be applied. These operators include the bitwise shift and sizeof operators. 1 C A Beginner s Guide by Herbert Schildt CRITICAL SKILL The const and volatile Qualifiers C has two type qualifiers that affect the ways in which variables can be accessed or modified. These modifiers are const and volatile. Formally called the cv-qualifiers they precede the base type when a variable is declared. const A variable declared with the const modifier cannot have its value changed during the execution of your program. Thus a const variable isn t really variable You can give a variable declared as const an initial value however. For example const int max_users 9 creates an int variable called max_users that contains the value 9. This variable can be used in expressions like any other variable but its value cannot be modified by your program. A common use of const is to create a named constant. Often programs require the same value for many different purposes. For example a program might have several different arrays that are all the same size. In this case you can specify the size of the arrays using a const variable.

TỪ KHÓA LIÊN QUAN
TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.