mirror of
https://github.com/autistic-symposium/master-algorithms-py.git
synced 2025-05-22 16:31:15 -04:00
Update array-check_mountain.py
This commit is contained in:
parent
0672ae9a3a
commit
896aaaf88f
1 changed files with 5 additions and 1 deletions
|
@ -1,3 +1,7 @@
|
|||
#!/usr/bin/env python3
|
||||
# -*- coding: utf-8 -*-
|
||||
# author: bt3gl
|
||||
|
||||
'''
|
||||
Given an array of integers arr, return true if and only if it is a valid mountain array.
|
||||
|
||||
|
@ -36,4 +40,4 @@ def valid_mountain_array(arr: list[int]) -> bool:
|
|||
|
||||
if __name__ == "__main__":
|
||||
arr = [0,3,2,1]
|
||||
print(valid_mountain_array(arr))
|
||||
print(valid_mountain_array(arr))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue