- 2

Write ✍️ a program to sort an array and find the index number of the required elements

Take an example of an array containing random numbers Arr = [10, 50, 13, 70, 19, 25, 60] Find the index value of x = 25 Use any sorting algorithm and sort and find the index value of 10 i.e "x" value

10th Jul 2022, 6:13 AM
Code Master
Code Master - avatar
2 Respuestas
+ 5
Please show your attempts link with a question.
10th Jul 2022, 7:01 AM
JaScript
JaScript - avatar
+ 1
Arr.sort() #sort the array print(Arr.index(25)) #index of 25
10th Jul 2022, 6:18 AM
Mihir Lalwani
Mihir Lalwani - avatar