Write a method to find the index of a specific element in an array.
EasyProblem Statement
Write a method to find the index of a specific element in an array.
Sample Input
Array: [10, 20, 30, 40, 50], Element: 30
Sample Output
2
Limits
Time: 2s · Memory: 256 MB