title: in Kotlin，The second call to joinToString is faster than the first call
body: <p>Here is my code</p>
  <pre><code>fun main() {
  val list1 = listOf(&quot;channel_name&quot;, &quot;timestamp_us&quot;, &quot;column_3&quot;, &quot;column_4&quot;, &quot;channel_name&quot;, &quot;timestamp_us&quot;, &quot;column_3&quot;, &quot;column_4&quot;)
  val start = System.nanoTime()
  list1.joinToString(prefix = &quot;(&quot;, postfix = &quot;)&quot;)
  val end = System.nanoTime()
  print(end - start)}
  </code></pre>
  <p>And the output is much more than 1,000,000.Usually it's about 8,000,000.
  However,if I change my code to this:</p>
  <pre><code>fun main() {
  val list1 = listOf(&quot;channel_name&quot;, &quot;timestamp_us&quot;, &quot;column_3&quot;, &quot;column_4&quot;, &quot;channel_name&quot;, &quot;timestamp_us&quot;, &quot;column_3&quot;, &quot;column_4&quot;)
  val list2 = listOf(&quot;channel_name&quot;, &quot;timestamp_us&quot;, &quot;column_3&quot;, &quot;column_4&quot;, &quot;channel_name&quot;, &quot;timestamp_us&quot;, &quot;column_3&quot;, &quot;column_4&quot;)
  list1.joinToString()
  val start = System.nanoTime()
  list2.joinToString(prefix = &quot;(&quot;, postfix = &quot;)&quot;)
  val end = System.nanoTime()
  print(end - start)}
  </code></pre>
  <p>The output usually is 15,000.</p>
  <p>So, can anyone explain why the output of the first code is <strong>600 times</strong> that of the second code?</p>
  <p>My computer is MacBook Pro (16-inch, 2019),</p>
  <p>jdk is jdk1.8.0_251,</p>
  <p>code run in IntelliJ IDEA 2020.2.2 (Community Edition)</p>
  <p>Kotlin plugin version is 1.4.10</p>