Computer Science, asked by juniper8, 5 months ago

Write an algorithm (pseudocode) to find the maximum element in an array? What is the basic operation in this problem?​

Answers

Answered by RuwaisnZaid
0

Explanation:

*/* IT MEANS THE NO OF ELEMENTS IN ARRAY = ITS LENGTH */*

BY THIS

L = EVAL(INPUT("ENTER A LIST"))

LENGTH = LEN(L)

COUNT = 0

FOR I IN L:

COUNT+=1

IF COUNT==LENGTH:

PRINT ("MAXIMUM ELEMENTS")

ELSE:

PRINT ("NOT MAXIMUM ELEMENTS")

Similar questions