Marking Identifiers in a program – Computer Sir Ki Class
  

Login
[lwa]



Solved Problem! #JAVA#3825    siteicon   siteicon  

Problem Statement - Marking Identifiers in a program

Write down both the programmer defined and java library defined identifiers in the following program

TC++ #3825

class SP_Identifiers
{
public static void main(String[] args)
{
double d=1.23d;
int a=5;
char b='a';
System.out.println(b+a+d);
}
}

Test it !

Solution


Programmer defined identifiers
SP_Identifiers
d
a
b

Java Library Defined Identifiers
main
String
args
System
out
println

Notes

  • Identifiers can be given to any variable, class, object, method, package etc. So every name given by the programmer or by programmers who created java packages and libraries, other than reserved words, keywords, operators, punctuators is an identifier.

Common Errors

  • Students often forget to mark java library defined identifiers correctly.
  • Students also forget to mark the class name also as an identifier.


Share

sunmitra| Created: 13-Mar-2018 | Updated: 13-Mar-2018|






Back