Computer Science, asked by PrapthiS, 1 month ago

What is an identifier ? What is the identifier forming rule of Java ?​

Answers

Answered by rajni6944
1

Answer:

ɪᴅᴇɴᴛɪғɪᴇʀ ғᴏʀᴍɪɴɢ ʀᴜʟᴇ ᴏғ ᴊᴀᴠᴀ ᴀʀᴇ ᴀs ғᴏʟʟᴏᴡs:

ɪᴅᴇɴᴛɪғɪᴇʀs ᴄᴀɴ ʜᴀᴠᴇ ᴀʟᴘʜᴀʙᴇᴛs, ᴅɪɢɪᴛs ᴀɴᴅ ᴜɴᴅᴇʀsᴄᴏʀᴇ ᴀɴᴅ ᴅᴏʟʟᴇʀ sɪɢɴ ᴄʜᴀʀᴀᴄᴛᴇʀs. ᴛʜᴇʏ ᴍᴜsᴛ ɴᴏᴛ ʙᴇ ᴀ ᴋᴇʏᴡᴏʀᴅs ᴏʀ ʙᴏᴏʟᴇᴀɴ, ʟɪᴛᴇʀᴀʟ ᴏʀ ɴᴜʟʟ ʟɪᴛᴇʀᴀʟ. ᴛʜᴇʏ ᴍᴜsᴛ ɴᴏᴛ ʙᴇɢɪɴ ᴡɪᴛʜ ᴀ ᴅɪɢɪᴛ. ᴛʜᴇʏ ᴄᴀɴ ʙᴇ ᴏғ ᴀɴʏ ʟᴇɴɢᴛʜ

Answered by Sneha0801
4

Answer:

Identifiers are fundamental building blocks of a program and are used as the general terminology for the names given to different parts of the program viz. variables, objects, classes, functions, arrays etc.

Identifier forming rule of Java are as follows:

1) Identifiers can have alphabets, digits and underscore and doller sign characters.

2) They must not be a keywords or boolean, literal or null literal.

3) They must not begin with a digit.

4) They can be of any length.

thank u

have a bangtastic day

Similar questions