Why  is  the  Java  a  strongly  typed  language ?

No comments

It  is  important  to  state  at  the  outset  that  Java  is  a  strongly  typed  language.  Indeed,  part  of  Java’s  safety  and  robustness  comes  from  this  fact.  Let’s  see  what  this  means.

First  :        Every  variable  has  a  type,  every  expression  has  a  type,  and  every  type  is  strictly  defined.

Second :      All  assignments  whether  explicit  or  via  parameter  passing  in  method  calls,  are  checked  for  type  compatibility.

            There  are  no  automatic  coercions  or  coercions  or  conversions  of  conflicting  types  as  in  some  languages.  The  Java  compiler  checks  all  expressions  and  parameters  to  ensure  that  the  types  are  compatible .  Any  type  mismatches  are  errors  that  must  be  corrected  before  the  compiler  will  finish  compiling  the  class

No comments :

Post a Comment

Subscribe

Milan Panda
Admin
About Me | Contact
Copyright 2023-2024 © Programming1011 . 🎀 Developed and Design By- Milan Panda. Happy Holi All Of You 🎀