Home  >  Q&A  >  body text

为什么感觉scala的难度与灵活性远大于java

scala的模式匹配、隐式转换、伴生对象伴生类、函数式等....特性要真正完全理解还是很难的

有大神能简单分析对比下jvm下的java和scala?

迷茫迷茫2762 days ago485

reply all(1)I'll reply

  • PHPz

    PHPz2017-04-17 17:26:26

    Personally, I think, Java算得上高级语言中语法糖最少的了,我把这总结为Java的干净,这种干净可以让初学者很容易熟练上手Java,也让Java保持了长期的生命力。因为缺少语法糖,所以JavaPrograms tend to look very clear, and understanding does not require too much brainpower. However, this has pros and cons. The drawback is that sometimes excellent syntactic sugar can speed up development and significantly reduce the cost of development. The amount of code.

    reply
    0
  • Cancelreply