Created
April 21, 2017 13:33
-
-
Save erokhins/82d890edb44d22ac245699c6a2c4356e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// FILE: 1.kt | |
package p3 | |
class A { | |
fun <T> test(a: List<T>): Int { | |
println("Function 1") | |
return 1 | |
} | |
fun test(b: List<Int>) { | |
println("Function 2") | |
} | |
} | |
// FILE: B.java | |
package p3; | |
import java.util.ArrayList; | |
import java.util.List; | |
public class B { | |
public static void main(String[] args) { | |
A a = new A(); | |
List<String> sList = new ArrayList<>(); | |
a.test(sList); | |
List<Integer> iList = new ArrayList<>(); | |
a.test(iList); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment