cannot assign value to “final” variable in java

前端 未结 7 1297
臣服心动
臣服心动 2020-12-31 08:44
 private void pushButtonActionPerformed(java.awt.event.ActionEvent evt)
{
    final int c=0;
    final JDialog d=new JDialog();
    JLabel l=new JLabel(\"Enter the E         


        
7条回答
  •  旧巷少年郎
    2020-12-31 09:30

    Just remove the final keyword from the declaration and continue your program. As final keyword means the value is unaltered.

提交回复
热议问题