Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...


Difference between prefix and postfix forms of the
++operator?

Answers were Sorted based on User's Feedback



Difference between prefix and postfix forms of the ++operator?..

Answer / ranganathkini

The prefix ++ operator first increments the value by one and
then returns the new value.

The postfix ++ operator first returns the value and then
increments it.

Is This Answer Correct ?    36 Yes 1 No

Difference between prefix and postfix forms of the ++operator?..

Answer / ravikiran

prefix will increment first and assigns to the variable
postfix will assing the value to the variable and then
increments

Is This Answer Correct ?    21 Yes 1 No

Difference between prefix and postfix forms of the ++operator?..

Answer / uday ray

They behave differently when they are used in expressions on
the right hand side of an assignment statement. A prefix
operator first adds 1 to the operand and the result is
assigned to the variable on left. On the other hand, a post
fix operator first assign the value to the variable on left
and then increments the operands.

Is This Answer Correct ?    5 Yes 2 No

Post New Answer



More Core Java Interview Questions

What is a databasemetadata?

0 Answers  


In a container there are 5 components. I want to display the all the components names, how will you do that one?

0 Answers  


How do you escape json?

0 Answers  


what is the use of abstract class and interface with example?

2 Answers   Cycore, DNS, Technoram,


When a thread is executing a synchronized method , then is it possible for the same thread to access other synchronized methods of an object ?

0 Answers  






What is the difference between pageContext and page implicit objects in jsp?

9 Answers   Gspann Technologies, Merrill Lynch, Polaris,


What is a map? What are the implementations of map?

0 Answers  


What is the nested interface?

0 Answers  


public class Base { public void myMethod(int a,intb) {} } // Uses myMethod and then hides it. public class DerivedOne extends Base { private void myMethod(int a,int b); } will this compile or not .yes or no. why

2 Answers  


Explain about collection interface in java?

0 Answers  


I want to know the host name and provider name for tcs web mail

5 Answers   RSG, TCS,


What are MalformedURLException and UnknownHost Exceptions and whey they will be thrown?

2 Answers  






Categories