MCPcopy Create free account
hub / github.com/Tiwarishashwat/InterviewCodes / swap

Method swap

NextPermutation.java:17–22  ·  view source on GitHub ↗
(int nums[],int i,int j)

Source from the content-addressed store, hash-verified

15 }
16
17 public static void swap(int nums[],int i,int j)
18 {
19 int temp=nums[i];
20 nums[i]=nums[j];
21 nums[j]=temp;
22 }
23
24 public static void reverse(int nums[],int i,int j)
25 {

Callers 2

nextPermutationMethod · 0.95
reverseMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected