In Java we can usually perform an assignment within the while condition. However Kotlin complains about it. So the following code does not compile:
while
(This Example for while loop ) Hope this example will help you..
Change from
while ((c = is.read(buffer)) > 0) { sb.append(String(buffer, 0, c, Charset.forName(UTF8))) }
is
to
while ({c = is.read(buffer);c}() > 0) { sb.append(String(buffer, 0, c, Charset.forName(UTF8))) }