擅长:python、mysql、java
<p>我不太清楚你为什么要用随机函数,但既然你知道B在哪里出现,你可以</p>
<pre><code>List[i] = 'B' # i is an integer, and it is where you want your thing to be
</code></pre>
<p>就像</p>
<pre><code>List[0] = 'B' # 0 is where a list starts
List[2] = 'B'
</code></pre>
<p>结果</p>
<pre><code>['B','','B','']
</code></pre>