为什么Kotlin可能比Java和Python更好 作为第一门编程语言?

On the 3rd Day of the 3rd Trivago Camp at about 3 PM I had a small discussion with one of our mentors Matthias Endler about the programming languages. The question was is it still relevant today in the world where each year hundreds of programming languages appear to stick with one language, being the “Die Hard Fan” of it, praying to it and using it whenever and wherever you can.

如今,我每天都在使用越来越多的Kotlin,因此,我来​​自Java背景就不足为奇了。 相反,Matthias作为Python的后端开发人员拥有丰富的经验。

Based on my personal learning experience, I was in mind that if you learned Java then you would not have a big problem with understanding other languages and the programming itself in general. So I proposed to Matthias that “It would be better to learn Java rather than Python as the first programming language” but Matthias did not agree with that thesis. More than that, almost 10 years ago he wrote the article exactly on the contrary proposal Overkill – Java as a First Programming Language.
I mean…. Come on, guys… It is Java! Who does not like Java?! :D

So I read his article and I would agree with some of his points. For example, I would agree with the point about the simple “Hello world” example, when you as a newbie may be horrified with so many unknown things in that small code snippet at once. I remember the discouraging and sleepless times in my last year of school because we started learning Java in the Doctor Java IDE, and the Doctor prefix itself already scared me at that time. There were times when I just was losing hours and hours of “debugging” just because I missed semicolons on some lines or miss-typed variable names.

但是,回想起来,我感谢Java医生,从第一天起就向我展示了“编程不是冰沙和核仁巧克力饼的幻想。 99.99%没什么。 该程序是否有效”。

因此,我认为现在声称“ Java比Python更好”并不是完全正确的,因为我没有足够的Python经验,所以我提出了另一个建议“为什么Kotlin可能比Java和Python更好? 第一种编程语言?”。

与Java相比,为了向新手展示简单的“ Hello world”,您实际上不需要这样说:“目前,我们不在乎类,新关键字,args,String [ ],关于那个公众,那个空虚等等(列表很长)。 只需看它打印即可!”。 因此,您需要显示的是:

Alt Text

另一个很好的例子可能是普通类:

Alt Text

关于Kotlin的伟大之处在于,您仍然拥有与Java差不多的概念,但是到最后,您可能学到的曲线不那么陡峭,所提供的信息量几乎相同。 您只需要开始编写一些代码,您就无需了解有关OOP的任何知识。 另一方面,如果您在不使用Eclipse或Intellij IDEA之类的高级IDE的情况下开始学习编程,那么用Kotlin编写代码就不会感到沮丧,因为您不必寻找遗漏的分号。

同时,当我们将Kotlin与Python进行比较时,Kotlin的一大优势可能是事实,它被广泛用于移动开发。 作为学生,您可能会问自己:“我为什么需要它?我可以在哪里实施这些知识?” 对于许多学生来说,“移动开发”可能比魔术的“用Python进行机器学习”更可行和更有启发性,在Python中,您基本上掌握了无数的数学。

另一个有趣的方面可能是大多数计算机科学“编程”类都基于Java或C ++(下降趋势)。 我从来没有听过有人说过“在大学,我们开始学习使用Python编程概念”。由于Java和Kotlin之间的兼容性和相似性,使大学课程适应Kotlin而不是Python会容易得多。 因此,如果大学不想被技术时代所束缚,那么Kotlin可能是对他们最好的,根本的解决方案。

最后,我希望所有的学生在开始学习编程后要勇于进取,不要放弃,因为有时候它看起来可能令人沮丧和沮丧,但我相信我们所有人都经历了这一过程。 给Kotlin一个机会,我相信您不会为此感到后悔。

from: https://dev.to//dzh/why-kotlin-may-be-better-than-java-and-python-as-the-first-programming-language-37d5

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值