We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 53b4295 commit 8010a74Copy full SHA for 8010a74
src/main/java/com/fishercoder/solutions/_283.java
@@ -19,7 +19,7 @@ public void moveZeroes(int[] nums) {
19
20
public static class Solution2 {
21
public void moveZeroes(int[] nums) {
22
- //this solutoin is the most optimal since it minimizes the number of operations
+ //this solution is the most optimal since it minimizes the number of operations
23
//the idea is to swap the non-zero element to the first zero number position
24
for (int i = 0, j = 0; i < nums.length && j < nums.length; j++) {
25
if (nums[j] != 0) {
0 commit comments