第 4 步:现在我们只需一行代码即可更改所有星星!

我们使用变量star_size来控制所有星星的半径。如果我们改变变量的值,所有星星的大小也会改变!

  • star_size的值更改为50
  • 点击运行以查看所有星星的大小变为50

To navigate the page using the TAB key, first press ESC to exit the code editor.

# THIS ACTIVITY IS IN PREVIEW ONLY MODE
  • Run Code
  • 提交作品
  • 下个活动
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)