• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

what is the flow of this program?

 
Radhakrishna Sharma Gorenta
Ranch Hand
Posts: 63
Google App Engine Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
 
Mohamed Sanaulla
Saloon Keeper
Posts: 3159
33
Google App Engine Java Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Did you try executing it? May be you can use a debugger to find out the flow of the program, or may be add print statements to track the flow.
 
Radhakrishna Sharma Gorenta
Ranch Hand
Posts: 63
Google App Engine Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the output of this program is:
A
B
A
but how ?
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here's a little hint: Replace

public class A {

by

public class A implements Serializable {

and see what happens. Can you conclude anything from that?
 
Radhakrishna Sharma Gorenta
Ranch Hand
Posts: 63
Google App Engine Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yes.we can get output if we do that. but i want to know flow for this
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic