printf can not print an integer
andrei.eremeev
andrei.eremeev at oracle.com
Thu Apr 23 14:17:48 UTC 2015
In REPL, printf is not a C-style printf. REPL's printf has parameters:
String a, Object...b, where 'a' is a template.
Andrei
On 04/23/2015 05:11 PM, Remi Forax wrote:
> 'printf' should be a method that takes an Object as parameter and not
> a String.
>
> -> printf(2)
> | Error:
> | incompatible types: int cannot be converted to java.lang.String
> | printf(2)
> | ^
>
> cheers,
> Rémi
>
>
More information about the kulla-dev
mailing list