Find Maximum in Array Problem
Find Maximum in Array Problem — ExecCode School DSA Practice
Solve the Find Maximum in Array problem on ExecCode. Free online school DSA practice in Arrays - Basics. Write and run code in Java, C++, Python — no signup required to run.
Problem description
Given an array of integers, find and print its maximum element. Your task is to solve Find Maximum in Array. The array will always contain at least one number.
Examples
Input 5 5 2 8 1 9; Output 9. Input 3 -1 0 1; Output 1
Constraints
1 <= n <= 10^5
Practice Find Maximum in Array free on ExecCode. Browse DSA problems, topic map, and placement guides.