This game helps you understand the Bubble Sort algorithm.這個遊戲幫助您理解冒泡排序演算法。
Pass: 遍歷: 0
How to Play:如何遊玩:
You will be presented with an array of numbers. Your goal is to sort them in ascending order using the Bubble Sort algorithm.您將看到一個數字陣列。您的目標是使用冒泡排序演算法將它們按升序排列。
The game will highlight two adjacent elements for you to compare.遊戲將突出顯示兩個相鄰元素供您比較。
Decide if these two elements need to be swapped to achieve ascending order. Click "Swap" if they do, or "No Swap" if they don't.判斷這兩個元素是否需要交換以實現升序。如果需要,點擊「交換」,如果不需要,點擊「不交換」。
Continue this process until the entire array is sorted.繼續這個過程,直到整個陣列排序完成。
Gameplay Description:遊戲玩法說明:
In Bubble Sort, you repeatedly step through the list, compare adjacent elements and swap them if they are in the wrong order.在冒泡排序中,您重複遍歷列表,比較相鄰元素,如果它們的順序不正確則交換它們。
The pass continues until no swaps are needed, indicating that the list is sorted.遍歷會一直持續到不需要交換為止,這表示列表已排序。
Your score increases for correct actions and decreases for incorrect ones.您的分數會因正確操作而增加,因不正確操作而減少。