左值lvalue 和 右值rvalue

1、lvalue: An expression that is an lvalue may appear as either the left-hand or right-hand side of an assignment.

2、rvalue: An expression that is an rvalue may appear on the right-hang but not left-hand side of an assignment.

Variables are lvalues and so may appear on the left-hand side of an assignment. Numeric literals are rvalues and so may not be assigned.

posted on 2014-04-22 16:18  江在路上2  阅读(86)  评论(0编辑  收藏  举报