tag:blogger.com,1999:blog-694855878384792308.post1904592323487026490..comments2024-03-21T06:26:49.387-07:00Comments on Java67: Difference between Static binding vs Dynamic binding in Java? [Answer]javin paulhttp://www.blogger.com/profile/15028902221295732276noreply@blogger.comBlogger3125tag:blogger.com,1999:blog-694855878384792308.post-81612330799143505322018-10-22T06:21:45.417-07:002018-10-22T06:21:45.417-07:00The trick resides in this line;
Collection c = ne...The trick resides in this line;<br /><br />Collection c = new HashSet();<br /><br />Subclass-Superclass binding is done at runtime, and since "print" is a static method, it would take SuperClass as a parameter.Anonymoushttps://www.blogger.com/profile/04260917588883548645noreply@blogger.comtag:blogger.com,1999:blog-694855878384792308.post-30569542563020888662018-04-06T23:28:46.585-07:002018-04-06T23:28:46.585-07:00Yes, it will. But can you brief me why it will hap...Yes, it will. But can you brief me why it will happen. I'm unable to understand that.Anonymoushttps://www.blogger.com/profile/07774115315154670257noreply@blogger.comtag:blogger.com,1999:blog-694855878384792308.post-14331752429960550042017-04-01T23:06:58.401-07:002017-04-01T23:06:58.401-07:00It will print Collection in the above asked exampl...It will print Collection in the above asked example<br />Anonymousnoreply@blogger.com