heimashi / kotlin_tips Goto Github PK
View Code? Open in Web Editor NEW[DEPRECATED] 用Kotlin去提高生产力:汇总Kotlin相对于Java的优势,以及怎么用Kotlin去简洁、务实、高效、安全开发的Tips
[DEPRECATED] 用Kotlin去提高生产力:汇总Kotlin相对于Java的优势,以及怎么用Kotlin去简洁、务实、高效、安全开发的Tips
你好,看了您的文章,写的非常好; 想请教下java10已经出来了,在正式项目中使用kotlin的好处还有多大。 以我仅写过helloword的经验看,比较喜欢data model和类似List.of的集合字面量,语法上确实简洁了些,但java中有lombok, java8有lambda, 函数式接口, java10又推出了var, 这些都大大的进了一步,在这种情况下想请教下团队要学习kotlin还有没有很有说服力的理由,尤其是kotlin的get set语法不太简洁
在将Android studio升级到3.0后 虽然支持了kotlin 但执行main方法 出现 classnotfound错误,网上的方法是用IDEA!!! 楼主自己有测试吗
這樣算是可以被override嗎
class Inner{
}
open class Parent{
open fun Inner.extendFunc3():String = ""
}
class Child:Parent(){
override fun Inner.extendFunc3():String = "override"
}
如题
input == null的判斷寫反了
再來這邊判斷的解釋會是一個一個往下串的,第一次看可能會無法馬上了解 ?: 往前對應到的地方是哪邊
input?.length ?: -1
if( ( if(input != null){input.length}else{input}) == null ){
-1
} else {
( if(input != null){input.length}else{input})
}
heimashi,你好。我是掘金的小编,在我的掘金昵称是:一颗香菜。我想邀请你把你的这篇 Kotlin_tips 发到掘金专栏,让更多开发者看到。这是我的个人微信:cx923373725 。如果你还有什么想要了解的,可以加我微信。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.