Đã hoàn thành

Python Program - Local Peak and a Power calculator

A) The function must be completed with time complexity O(log(N)).

Find a local peak from an input unsorted array, a local peak is defined as any element i that is greater than element i+1 and i-1 (neighbouring elements in the list).

The first and last element only have to be greater than their single neighbouring element to be a local peak.

Return as output an integer representing the index of the element in the array that is a local peak, if multiple peaks exist, return the first found peak (ie. only return one peak)

For example; Calling local_peak([0,2,4,6,5,2]) returns 3.

B) The function must have a complexity of O(log(N)).

You cannot use the inbuilt function Pow or the operator ** for this question.

Write a function power(n, p) that takes a number and a power and returns the number raised to that power

For example; Calling power(2,8) returns 256.

Kĩ năng: Python

Xem nhiều hơn: python find peaks in array, scipy find valleys, find all peaks in an array python, python find local maxima 2d array, scipy.signal.find_peaks example, find all the local maxima in an array, find peaks python, python find peaks and valleys, help writing python program enter payroll information, python program extract info website, python program craps, program audio peak detection, python program checks validity numbers, interface python program reads csv outputs csv, python program play craps, program calculate number power, python program count days, python program extract data html, python program order taking, python program pcr primer

Về Bên Thuê:
( 0 nhận xét ) Truganina, Australia

ID dự án: #21367529

Được trao cho:


Hi, there. (✿◠‿◠) Perfect Quality & Fast-Delivery are Promised! As you can see in my profile, I have done a lot of Python projects like this. As I majored algorithms & math, I can complete your project in 1 day. I alwa Thêm

$20 AUD trong 1 ngày
(62 Đánh Giá)

5 freelancer đang chào giá trung bình $23 cho công việc này


Hello, I went through your requirement specification and I can help you design both functions in Python in O(log(N)) complexity of time space. Please feel free to contact me to discuss further. Regards, Sunny

$30 AUD trong 2 ngày
(25 Nhận xét)

Hi ⭐ I am very confidence, I can finish in a 1hr. I have read your requirement very carefully. So I am really confidence your project. Python is my highest skill so I have rich experiences with python GUI and Game and Thêm

$30 AUD trong 1 ngày
(37 Nhận xét)

Thank you for giving me a chance to bid on your project. i am a serious bidder here and i have already worked on a similar project before and can deliver as u have mentioned I have checked your requirements. We have Thêm

$21 AUD trong 7 ngày
(0 Nhận xét)

Hi, I have 10 years of working experience in python development and can easily handle your project please inbox me so we can discuss further looking forward to work with you.

$15 AUD trong 1 ngày
(0 Nhận xét)