answer: D
x+y = int - numeric promotion rule
[2]method signature parameter
1. first phase without boxing/unboxing
there is no match type/ there is no widdening type
2. phase
allowing boxing and unboxing
int -> Integer (autoboxing)
Integer->Object //regular downcasting No explicit cast is necessary
The output of the code is D. Object value 25. The code compiles and runs without any errors. In the expression x+y, both operands are promoted to int before the addition is performed, resulting in an int value of 25. Since there is no process method that takes an int argument, the int value is then boxed into an Integer object and passed to the process(Object v) method, which prints Object value 25.
This section is not available anymore. Please use the main Exam Page.1z0-819 Exam Questions
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
ASPushkin
11 months, 2 weeks agomendjijet
1 year, 5 months agoOmnisumem
1 year, 10 months agotmuralimanohar
2 years agoStavok
2 years, 1 month agoStavok
1 year, 11 months agoMukes877
2 years, 1 month agoObalt
2 years, 5 months ago