problem statement::
input :: arr [ ] = {10,20,80,30,60,50,110,100}
z = 110;
output :: 6
CODE ::
def search( arr , z ):
for i in range(len ( arr ) ):
if arr [ i ] == z :
return i
return -1
problem statement::
input :: arr [ ] = {10,20,80,30,60,50,110,100}
z = 110;
output :: 6
CODE ::
def search( arr , z ):
for i in range(len ( arr ) ):
if arr [ i ] == z :
return i
return -1
Do Contact For More Information
0 Comments