• Post Reply Bookmark Topic Watch Topic
  • New Topic

Which one is correct ?  RSS feed

 
Nikhil Sagar
Ranch Hand
Posts: 216
Java Linux Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1
  • Compiler creates reference variable.

  • 2
  • reference variables are created at compile time.

  • 3
  • there is only one thing compiler creates and that is byte code

  • 4
  • compiler reserves the memory for the variables to be created at run time.on the bais of there decleration type.
  •  
    Campbell Ritchie
    Marshal
    Posts: 56593
    172
    • Likes 1
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Which do you think? We don’t simply answer questions like that. you should also always tell us where the question is from, to avoid copyright problems, and some sort of hint of what the thread is about in its title.
     
    Nikhil Sagar
    Ranch Hand
    Posts: 216
    Java Linux Tomcat Server
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Campbell Ritchie wrote:Which do you think? We don’t simply answer questions like that. You should also always tell us where the question is from, to avoid copyright problems, and some sort of hint of what the thread is about in its title.

    Okay,
    this question is asked by one of class met of mine to me.i replied him i think only option 3rd is correct and all others are incorrect although i am not sure about the last part.

    what the thread is about in its title


    I am really very sorry about that, i assure you i will take care about that.
     
    Campbell Ritchie
    Marshal
    Posts: 56593
    172
    • Likes 1
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    You are right that only the 3rd is correct. 1 and 2 are almost the same thing as each other, done by the JVM at runtime. 4 looks like nonsense. Space is allocated and cleared at runtime as required.
     
    Nikhil Sagar
    Ranch Hand
    Posts: 216
    Java Linux Tomcat Server
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Campbell Ritchie wrote:You are right that only the 3rd is correct. 1 and 2 are almost the same thing as each other, done by the JVM at runtime. 4 looks like nonsense. Space is allocated and cleared at runtime as required.

    Thanks, Sheriff.
     
    Campbell Ritchie
    Marshal
    Posts: 56593
    172
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    You are welcome
     
    • Post Reply Bookmark Topic Watch Topic
    • New Topic
    Boost this thread!