首页 > 编程知识 正文

java变量名可以是中文吗,java可以使用汉字变量名吗

时间:2023-05-06 04:55:48 阅读:227620 作者:3384

An identifier is an unlimited-length sequence of Java letters and Java digits, the first of which must be a Java letter.
Letters and digits may be drawn from the entire Unicode character set, which supports most writing scripts in use in the world today, including the large sets for Chinese(//中文), Japanese, and Korean. This allows programmers to use identifiers in their programs that are written in their native languages.(//重点在这里)
当个人感觉该是尽量用英文加中文注释的方式符合习惯,这个仅仅是为了打破书本的规定。

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。