Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/codemistic/Data-Structures-and-Algorithms
/ swap
Method
swap
Java/Leetcode/Leetcode448.java:34–38 ·
view source on GitHub ↗
(int[] arr, int a, int b)
Source
from the content-addressed store, hash-verified
32
}
33
34
static
void
swap(
int
[] arr,
int
a,
int
b){
35
int
temp=arr[a];
36
arr[a]=arr[b];
37
arr[b]=temp;
38
}
39
}
Callers
1
disappear
Method · 0.95
Calls
no outgoing calls
Tested by
no test coverage detected