From the previous video of our ongoing course on Core Java we have seen that what are Logical operators in Java and how many Logical operators do Java supports. Now in this video we are going to see what are Assignment operators in Java.
Assignment operators in Java programming language are used to assign values to the variables. The following are the Assignment operators in Java used :
To gain an accurate understanding about Assignment operators in Java, now we will do Programming,
public static void main (String args)
System.out.println("+x=" + ans);
System.out.println("-y=" + ans);
System.out.println("++x=" + ans);
System.out.println("--y=" + ans);
System.out.println("x++=" + ans);
System.out.println("y--=" + ans);
So, this is how Assignments Operators in Java works and by completing Assignment operators, we have covered all the Operators of Java in our Core Java course. In the next video we will see what are Flow Control Statements in Java and what are Conditional Statements in Java.
Have a friend to whom you would want to share this course?