标识符关键字和注意点

标识符关键字

abstract抽象的 assert

boolean break

byte case

catch char

const(保留字) continue

default do

double else

enum extends

final finally

float for

if goto(保留字)

implements import

int interface

long native

new package

private protected

public return

short static

strictfp super

switch synchronized

this throw

throws transient

try void

volatile while

 

 

标识符注意点

image-20201224211434872

 

 public class Demo01 {
     public static void main(String[] args) {
 
         String  王者荣耀 ="百星王者";
         //String 王者荣耀 ="倔强青铜";
         System.out.println(王者荣耀);
 
 
 
         //大小写十分敏感
         String Man="xiatiandesuyan";
         String man="xiatiandesuyan";
 
 
         String name="xiatiandesuyan";
 
 
         String Ahello ="xiatiandesuyan";
         String hello ="xiatiandesuyan";
         String $hello ="xiatiandesuyan";
         String _hello ="xiatiandesuyan";
 
 
         String _  ="xiatiandesuyan";
         //String class ="xiatiandesuyan";
         //String 1hello ="xiatiandesuyan";
         //String #hello ="xiatiandesuyan";
         //String *hello ="xiatiandesuyan";
 
 
    }
 }
 

 

posted @ 2020-12-24 21:16  夏天的素颜  阅读(32)  评论(0编辑  收藏  举报