필터 지우기
필터 지우기

How to write the program for pick the first five element from an array than next five and store their individual sum in new array?

조회 수: 1 (최근 30일)
How to write the program for pick the first five element from an array than next five and store their individual sum in new array?

채택된 답변

David Hill
David Hill 2022년 6월 8일
a=randi(100,1,50);%an array
n=sum(reshape(a,5,[]));%sum of 5 elements placed in new array

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Matrices and Arrays에 대해 자세히 알아보기

태그

제품

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by